Interested in a ServiceNow event built for developers? Registration for now[dev]26 is officially open!

Work Notes for Attachment Upload to Record Producer

Vaniyaa_x
Tera Contributor

Hi All,

Is it possible to generate a work notes when a attachment is attached to record producer

Vaniyaa_x_0-1789794834544.png

 

2 REPLIES 2

RaghavendraGund
Giga Guru

Hello @Vaniyaa_x 

If I understand your Question correctly, At Submit time: requester attaches a file on the producer form and the created record should carry a work note like"Attachment added: test.pdf".

if this is what you need, then you may not have to build anything.

When a file is attached on the record producer form and the form is submitted, the file carries over to the record that gets created and appears in the activity stream on its own. I tested this on a PDI with the out-of-box Create Incident record producer. On the classic form it shows as "Attachment uploaded" with the file name and size; an image file shows as "Image uploaded" with a thumbnail. The same entry appears in the portal ticket under the Activity tab, so the person who submitted it can see it too.

What it is not is a work note. The Work notes field stays empty and no journal entry is written for the upload. So if the reason you want a work note is one of these:

a notification that triggers on work notes
a flow or business rule condition that checks work notes
a report or workspace view that reads the work notes field

then the activity entry won't cover it and you would need a business rule on sys_attachment to write the note yourself

Please Mark "Helpful" and Solution Accepted, if my reply added any Value to your question.

Regards
Raghavendra G




abirakundu23
Giga Sage

Hi  ,

Yes, it is possible. You can write business rule on "sys_attachment" table when attachment is added in Record Producer all attachment related details will be added on target table's worknotes.

Alternatively, you can write same logic in record producer script as well.

Make sure only specific record producer oriented attachment updated then only target record worknotes update.

Please mark helpful & correct answer if it's worthy for you.