- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-23-2017 10:23 AM
Hi team,
I just imported images using a zip file attachment into db_image table.
We also have a Images table in our scoped application with an image field and some additional metadata.
Now that I imported the images, how can I assign an imported image to a Image field in my application?
I looked into the Image field documentation : Add an image field , but found no instructions to do that.
Maybe I can use GlideRecord api?
Please help.
Kind regards.
-
Eduardo
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-29-2017 01:52 PM
Hi Team,
After doing some additional research I found the solution which I will share for the benefit of the community:
How to Copy One image(Field 1) to another image(Field 2) both fields are of Image type
Basically we can use GlideSysAttachment to link an image imported in db_image table to an existing IMage field in any scoped application table.
var ga = new GlideSysAttachment();
var attachments = ga.copy('db_image', yourImageAttachment.sys_id, 'ZZ_YYx_your_table',row.sys_id);
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-23-2017 02:25 PM
Hi Eduardo,
Kindly explain the significance as to why you want to go anti clockwise instead clockwise.
If you want some image to be link to your image field just make image field as reference field and it should reference to db_image table.
else directly upload the image on to image field as field type as image instead uploading it to db_image and then trying it to bring it on form.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-29-2017 01:52 PM
Hi Team,
After doing some additional research I found the solution which I will share for the benefit of the community:
How to Copy One image(Field 1) to another image(Field 2) both fields are of Image type
Basically we can use GlideSysAttachment to link an image imported in db_image table to an existing IMage field in any scoped application table.
var ga = new GlideSysAttachment();
var attachments = ga.copy('db_image', yourImageAttachment.sys_id, 'ZZ_YYx_your_table',row.sys_id);
Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-25-2018 05:45 AM
I have tried this and could not get this to work. I don't see the images being attached to the image field. Any suggestions?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-07-2024 06:56 AM
@samadam did you find any solution?