Needs to update Kenna priority field value for all CIs
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2023 08:48 AM
Hi Community,
We need to update the Kenna priority value to "10" for all the CIs in cmdb_ci table.
Could you please suggest any fix script using which we can achieve this?
Thanks and regards,
Nikhil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2023 09:13 AM
Hi @Nikhil kumar ma ,
if you have data lookup to populate the priority then you need to set the data lookup fields like impact and urgency.
If there is no such data lookup rules then use below code to set priority
var grCmdb = new GlideRecord('cmdb_ci');
grCmdb.query();
//if yu have any data look for priority then need to use imapct and urgency to set priority
//grCmdb.impact='10';
//grCmdb.urgency='10';
grCmdb.priority='10'//add your prioriy name
grCmdb.updateMultiple();
ServiceNow Community MVP 2024.
Thanks,
Pavankumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-24-2023 09:16 AM
Hi Pavan,
Can we write this script without using impact and urgency? using Kenna priority only.
Regards,
Nikhil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-27-2023 09:56 PM
Hi @Nikhil kumar ma ,
If it is Data Lookup then you have to use impact and urgency only.
ServiceNow Community MVP 2024.
Thanks,
Pavankumar