var mrvs; var itemID = '98036486209173847gdbcdj879'; var ritmGR = new GlideRecord('sc_req_item'); if (ritmGR.get(itemID)) { mrvs = ritmGR.variables.access_list; } var rowCount = mrvs.getRowCount(); for (var i = 0; i < rowCount; i++) { var row = mrvs.getRow(i); var app = row.application; var accessLevel = row.access_level; gs.print(app + ' ' + accessLevel); } Output: *** Script: 123 read *** Script: 456 full *** Script: 678 read_write
How to Parse data from Variable Set ServiceNow?
Working Code Asked question September 16, 2024