- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2024 02:32 AM
Hi ServiceNow Users,
I have a general question. We have created a scheduled script execution that runs every day at 10'o'clock and checks specific incident fields. If certain values are true, the script updates the incident accordingly and also adds a work note into the record.
Everything works perfectly - however, the script somehow runs as the user who created the script so that all work notes are also being added AS the user who created the script. This leads to some notifications not running as well as we don't want the script to stop in case the user leaves the company in the future. Is there are possibility, kinda compared to Scheduled Import Jobs for example, to run the script as system user or so?
Thank you!
Regards
Elena
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2024 03:17 AM - edited 03-08-2024 03:18 AM
Hi @ehgebla ,
You can bring the field Run as from List Layout and select the user but make sure that user is active and have the required roles,
To bring this field on form You can do the following,
1. Right click on Scheduled Job -> configure ->List Layout
2. from slush bucket move Run as from left to right and save it.
Once you get this on form you can set the value, save it and execute it.
Please check and Mark Helpful and Correct if it really helps you.
Regards,
Swathi Sarang
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2024 03:08 AM
Hi Raaj,
not there for me. Also checked Personalized Form, everything is checked.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2024 03:17 AM - edited 03-08-2024 03:18 AM
Hi @ehgebla ,
You can bring the field Run as from List Layout and select the user but make sure that user is active and have the required roles,
To bring this field on form You can do the following,
1. Right click on Scheduled Job -> configure ->List Layout
2. from slush bucket move Run as from left to right and save it.
Once you get this on form you can set the value, save it and execute it.
Please check and Mark Helpful and Correct if it really helps you.
Regards,
Swathi Sarang
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2024 03:36 AM
this was too easy i even feel too ashamed to say thank you haha. thanks a lot. i actually didn't checked the form layouts, since the run as was there when it wasn't a script execution. i should have thought about that myself...
anyways; thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-08-2024 03:38 AM
@ehgebla no worries, sometime it happens 😁
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-23-2025 04:13 PM
I think the best we can do is to run it as "System Administrator". There doesn't seem to be a way to run it as "System" like a flow...