Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

Conditions for automatically running a fix script

bjornvandommele
Kilo Explorer

When I create a fix script, will upgrading my instance to a different version of ServiceNow automatically execute this fix script or do I have to run it by hand? Are fix script executed after a clone operation? Under which conditions is a fix script run automatically by ServiceNow?

1 ACCEPTED SOLUTION

paramveer
Mega Guru

Hi Bjorn :



Fix script never runs automatically. You need to run it manually after clone too. You can schedule a script by scheduled job.


Go to left navigation -->scheduled job--->click on new---> Choose automatically running the script of your choice.



Copy paste you fix script code here and schedule it accordingly.



More Information please visit :



Creating a Scheduled Job - ServiceNow Wiki



Thanks,


Param


View solution in original post

2 REPLIES 2

paramveer
Mega Guru

Hi Bjorn :



Fix script never runs automatically. You need to run it manually after clone too. You can schedule a script by scheduled job.


Go to left navigation -->scheduled job--->click on new---> Choose automatically running the script of your choice.



Copy paste you fix script code here and schedule it accordingly.



More Information please visit :



Creating a Scheduled Job - ServiceNow Wiki



Thanks,


Param


Are there really no situations where a fix script will run automatically?



I am developing a scoped application and when I load it into a new instance from Studio via a source control import, I can see that my fix script was run without my   having to navigate to the Fix Scripts list and run it manually.



I can see log updates and record updates that only the fix script can perform.



What's even more interesting is that I have a second fix script that isn't run automatically, and as far as I can tell, the only difference in the settings is that the Run Once value is true. I've deleted the app a few times off the instance and reloaded it, so I wonder if it literally ran once during the first load and won't for any future loads.