How do I delete attachments after an incident is closed?

trishlipe
Giga Expert

I am needing to delete a couple of attachments on one of our incidents. When I go to Manage Attachments, the option to delete these is no longer available. I assume it is because the incident is closed. Is there a way to delete these?

1 ACCEPTED SOLUTION

adamjgreenberg
ServiceNow Employee
ServiceNow Employee

You will need to get the sys_id of the incident record and then navigate to the attachment table (this is not an enabled module by default)



Then navigate to - yourinstance.service-now.com/sys_attachment_list.do?sysparm_query=table_sys_id%3D{sys_id of the record)


Screen Shot 2018-01-31 at 8.23.21 AM.png


Check the box and select "delete" - Confirm delete.



Screen Shot 2018-01-31 at 8.24.54 AM.png






Finally, verify the attachment is no longer available from the record.



Screen Shot 2018-01-31 at 8.25.34 AM.png


View solution in original post

6 REPLIES 6

Allen Andreas
Administrator
Administrator

You need to update Delete ACL of attachment table.



Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

Actually, my apologies, this is the answer:



find_real_file.png



If you wish to enable it for everyone.



There's a client script that's enabled by default.



Or you could just make it false, do all your deleting, then turn it back to true.



Better and faster than going through tons of sys_ids



Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

Hi Trisha,



I just wanted to check back in and see if this question has been answered.



Thanks!



Please consider marking my reply as Helpful and/or Accept Solution, if applicable. Thanks!

jezram
Tera Contributor

Hi Trisha,



Try to create a business rule on after, it will be executed after the state changes to Closed, and then you can get rid of the attachment by a script just deleting the reference record of the attachments from sys_attachment table, all attachments are stored in that table and you can find the related ones by the Table sys id field.



I hope this will be helpful for you!