- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-16-2014 04:09 AM
Hi SNC,
What will be the quickest way to go through all the records in a table and update a certain field in all of those records?
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-16-2014 05:04 AM
script based on the info you have provided ...
var gr = new GlideRecord('u_org_admin');
gr.query();
while(gr.next())
{
var referenceRecord = gr.u_org_admin.getRefRecord();
referenceRecord.u_is_org_admin = true;
referenceRecord.setForceUpdate(true);
referenceRecord.setWorkflow(false);
referenceRecord.update();
}

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-16-2014 04:12 AM
Open the table suppose incident.LIST. Right click on the header and click "Update All".
Regards,
Harish.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-16-2014 04:24 AM
Yep, I thought of that but it does not work for me for some reason. I have a table which holds User records, and one field in there is a checkbox of the User form, which is false, and I would like to make it true.
I selected Update All, mark that to True, but nothing happens....weird

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-16-2014 04:30 AM
That is the way we can update all records not sure whats the issue.
You can update by using glideecord try that way if update all not working.
Regards,
Harish.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-16-2014 04:37 AM
i trust scripts ... try a background script ..
Filter the records in list view and copy the query....
var gr = new GlideRecord(table);
gr.addEncodedQuery('paste the copied query');
gr.query();
while(gr.next())
{
gr.field = value;
gr.setForceUpdate(true);
gr.setWorkflow(false);
gr.update();
}