Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2024 12:52 PM
Try the following from Arpan's script:
// Batch Update records
while (true) {
var needit_gr = new GlideRecord('insert_the_name_of_the_needit_table');
needit_gr.addNullQuery('u_requested_for_email');
needit_gr.setLimit(100);
needit_gr.query();
var numberRecs = needit_gr.getRowCount();
// see if we're done, if so exit while loop
if (numberRecs == 0)
break;
gs.info("Batch update records: found " + numberRecs + " to process.");
while(needit_gr.next()){
needit_gr.setValue('u_requested_for_email', needit_gr.u_requested_for.email);
needit_gr.update();
}
}