Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-15-2019 03:49 AM
This is the result I got. I had limited the result set to 4 for testing.
var incidentGR = new GlideRecord('incident');
var oldDescription = '';
incidentGR.addEncodedQuery('stateNOT IN6,7,8');
incidentGR.setLimit(4);
incidentGR.query();
while(incidentGR.next())
{
oldDescription = incidentGR.description;
incidentGR.description = incidentGR.description + '.';
incidentGR.update();
gs.log('Incident ' + incidentGR.number + ' has been updated. Old Description: ' + oldDescription + '. New Description: ' + incidentGR.description);
}