How to add scheduled job script in update set?

sharley
Tera Contributor

Hi,

I have created a Local Update Set and then created a Scheduled Job Script and Report. After testing, if it is successful I will have to move the Local Update Set from Dev to Prod. But the issue is "The Scheduled Job Script is not captured in the update set". so I would like to know if there is any way to move the scheduled job script to Prod safely. 

6 REPLIES 6

Anurag Tripathi
Mega Patron
Mega Patron

Hi,

You can just export it into XML and Import it in the target instance, it works the same way and I have done it that way multiple times, its safe.

-Anurag

-Anurag

OR

Make the update set you want to capture this your current update set and just run this background script

 

 

var gr = new GlideRecord('sysauto_script');
gr.get('<sys_id of your scheduled job>');
var gum = new GlideUpdateManager2();
gum.saveRecord(gr);

It will get captured in your current update set.

 

-Anurag

-Anurag

Slava Savitsky
Giga Sage

Check out this free utility from ServiceNow Share:

Add to Update Set Utility

It lets you add almost anything into an Update Set, even data.

pawan k singh
Tera Guru

You can add Scheduled job in update set by clicking on Related links "Add to Update Set" option. It will move the xml to your current update set.

Please Mark this answer helpful/ if it helped you.

find_real_file.png

Regards

Pawan K Singh