Hello all, We have two incidents and those two incidents are in cancelled state and state in changed
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-30-2024 06:04 AM
Hello all, We have two incidents and those two incidents are in cancelled state and state in changed to read only mode. Now my question is can we change state to close from cancelled for those two incidents.
3 REPLIES 3
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-30-2024 06:12 AM
Hi @Tulasiram1
You have to run a background script to update it
If my answer has helped with your question, please mark my answer as accepted solution and give a thumb up.
Regards,
Piyush Sain
Regards,
Piyush Sain
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-30-2024 06:17 AM
Yes we can do this follow this code.
Try this code in background script.
var gr = new GlideRecord('incident');
gr.addEncodedQuery('state=8');
gr.query();
while(gr.next()){
gr.close_code ='known error';
gr.close_notes = "closed incident";
gr.state= 7 ;
gr.update();
}
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2024 11:50 PM