Courseiva

SNOW-CAD

Study mode — explanations shown

1

Application development using ServiceNow Studio

hard

Refer to the exhibit. What is the primary issue with this script if it is intended to update all incidents in state 'New' (state=1) to priority 2?

Exhibit

var gr = new GlideRecord('incident');
gr.addQuery('state', 1);
gr.query();
while(gr.next()) {
    gr.setValue('priority', 2);
    gr.update();
}
0 of 30 answered