Copy attachment from record producer variable to record is not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2024 08:10 AM
I am trying to copy an attachment from variable in record producer to record with the below BR, but its not working
I am using Async insert BR on the table (x_as_request) in scoped app.
In line number 5, im getting 'x_as_request' table in the log.
In the attachment table, I am seeing the table name as ZZ_YYsc_cart_item and the table sys id is empty.
I assume table sys id should not be empty . Please help me here attachment is not getting added to record.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2024 08:48 PM
I commented out line number 6, still its not going to if.
Why table_sys_id is coming as empty in attachment table. Is it because I was using an attachment type variable?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2024 08:51 PM
table_sys_id should be present in sys_attachment. that's the issue.
Did you verify with some other catalog item/record producer with attachment variable?
if the issue is coming for that as well, seems some platform issue
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2024 09:14 PM
For other record producers also, the table sys id is coming as empty.
If that is the case, then I tried with a different approach also , I am taking a custom drag and drop attachment as below.
I have written a on submit catalog client script but it is not working, here the attachment is getting
Below is the script, but everytime the row count is getting as 0
I assume in line number 31, I was comparing proof var(which is sys id of record producer), but in the attachment table, it is appearing like the file name that I was attaching. Please help here.
I even raised an another post, I will tag you there, can you please guide, so I can achieve my requirement in the other way atleast
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2024 10:08 PM
your earlier approach should work.
Did you try for record producer in global scope or custom scope?
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-16-2024 10:11 PM
@Ankur Bawiskar Record producer is in custom scoped application
you meant to say, catalog client script right? Custom drag and drop?