Move attachement in transform map

mregragui_ext
Tera Contributor

Hey community i have a custom and an oob table and i want to move the records from custom to oob the thing is that i did not map the records with numbers so the two tables will have same records with different number and i want to move also the attachemet how can i do this (move also the attachemet)

3 REPLIES 3

Community Alums
Not applicable

Hi @mregragui_ext ,

The best thing which you can do is using GlideSysAttachment copy() in an 'after' transform script, so that after your target record is created the attachments are copied to it.

Also, refer to this thread which uses a flow : https://www.servicenow.com/community/now-platform-articles/transform-attachments-with-flow-designer/...

 

Ankur Bawiskar
Tera Patron
Tera Patron

@mregragui_ext 

Is this for import set?

Please share some details on how are you receiving the attachment data, file name, content type etc

Is that an excel file or some other file?

You can add file to target record using onAfter transform script which will run for every row of your import set table.

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

@mregragui_ext 

Hope you are doing good.

Did my reply answer your question?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader