ServiceNow retrieve a particular service catalog variable by its name and value
name (actually the variable sys_id)
value
var grMTOM=new GlideRecord('sc_item_option');
var sQuery='item_option_new=818596ea1ba37510af03dce0b24bcbff^value=test@email.com';
grMTOM.addEncodedQuery(sQuery);
grMTOM.query();
if (grMTOM.next()){
gs.print(grMTOM.sys_id);
gs.print(grMTOM.value);
}
Comments
Post a Comment