Is it possible to access scratchpad in transform scripts??

asoni1
Kilo Contributor

Is it possible to access scratchpad in transform scripts??

I have a requirement, where in I need to compare target table records with the input records and mark the unwanted records in target table as inactive 

 

Please recommend.

10 REPLIES 10

Pradeep Sharma
ServiceNow Employee
ServiceNow Employee

Hi Asoni,

 

You may find below blog helpful.

https://community.servicenow.com/community?id=community_blog&sys_id=7cc66514db882380e0e80b55ca961965

 

- Pradeep Sharma

Pradeep Sharma
ServiceNow Employee
ServiceNow Employee

Can you please provide some additional details on what you are trying to accomplish?

 

- Pradeep Sharma

Gurpreet07
Mega Sage

Alternatively you can GlideRecord import set table in onComplete script and target record field in there can be used to update target table record. Otherwise there's a way to put data in session and then access that later on.

https://docs.servicenow.com/bundle/kingston-application-development/page/app-store/dev_portal/API_re...

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

scratchpad variables are used in display business rule and workflow scratchpad in workflows

for your requirement you can use onbefore transform script; query target table by using the source values and mark unwanted records as inactive

in this case you won't require any field map

Mark Correct if this solves your issue and also mark Helpful if you find my response worthy based on the impact.
Thanks
Ankur

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