Execute Now button is not executing the code of scheduled job
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-17-2018 07:29 AM
Hi,
I have written a scheduled job to execute daily at 6 am. After writing the code when I saved it and clicked on execute now button, page refreshes but it do not do anything i.e. script do not executes.
But when I copy the same code and executes it from Background script it works perfectly fine. Any idea why is that ?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-17-2018 09:16 AM
Please apply cross scope privileges between both your scoped app tables.
https://docs.servicenow.com/bundle/kingston-application-development/page/build/applications/reference/c_CrossScopePrivilegeRecord.html
Regards,
Sachin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-17-2018 07:43 AM
Hi Kamlesh
Type sys_trigger.list into the Filter Navigator and sort the records by created. This should tell you if the Scheduled Job is triggered or not.
If yes, then there must be an issue with the script.
Thanks
Matt
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-17-2018 08:13 AM
Hi Matt,
I checked that as well. Scheduled job didn't execute at all. Is it because my schedule job is in different application i.e. not global. If yes then is this behavior expected ?
Thanks,
Kamlesh

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-17-2018 08:39 AM
Yes that is possible if global application scope does not have access to edit the records in your scoped app,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-11-2020 05:32 AM
Hello Kamlesh,
Did you figured solution for this.
Thanks,
Amarjeet Pal