Script Background & Fix Scripts

Khanna Ji
Tera Guru

What is Script Background & Fix Scripts?

I think both are used for running ad hoc scripts without the use of any workflow object or BR etc. But what is the difference?

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Swathi,

Fix script is best approach when you install new application or want some data fixes to be running after making some changes in prod. The best feature of fix script is you can monitor it's execution and check the progress and you can kill the transaction as well.

Never execute any insert/update/delete script from script background since if it takes long time the browser will timeout and also if any error comes in the script it may get into some loop.

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

View solution in original post

16 REPLIES 16

Hi Swathi,

Ideally fix script are used for inserting/updating records.

Regards

Ankur

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

Hi Swathi,

Any update on this?
Can you mark answer as correct, helpful if you were able to achieve the requirement. This helps in removing this question from unanswered list and helps users to learn from your thread. Thanks in advance.

Regards
Ankur

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

Note that fix scripts are also captured in Update Sets, so they are typically part of a deployment run book.


If this answer was helpful, I would appreciate if you marked it as such - thanks!

Best
Daniel

Jaspal Singh
Mega Patron
Mega Patron

Hi Swathi,

 

Fix Script - Is specific for data of an application that has been installed/upgraded.

Background script-mass creations, updates, and deletions of records. Also, used for troubleshooting.

 

Thanks,

Jaspal Singh

 

Hit Helpful or Correct on the impact of response.

Abhinay Erra
Giga Sage

Both of them are server side scripts and as you mentioned are used for running adhoc scripts. I would prefer fix scripts when I want to capture it in an update set or export it to xml and migrate it to production. This way it is much cleaner and easy to push the code to higjre instances like QA, UAT and prod.