Interested in a ServiceNow event built for developers? Registration for now[dev]26 is officially open!

List Collector Variable on Catalog Item only show sys_id

Not applicable

Hi all, 

I have a catalog item with a list collector variable. The list collector is a reference field to the sys_user_group table. My issue I am trying to get the responses on an email notification but it's only returning the sys_id of the groups. How I can get the Display Value or the actual name of the group in the email notification? I am using the flow designer to send the notification.  

find_real_file.png

1 ACCEPTED SOLUTION

Not applicable

Hi @Muhammad Khan and@Mohith Devatte ,

Thank both for your responses, but I was unable to find a solution using flow designer so I end it up using the notification outside flow designer. I create a notification and I called the variable for the list collector.

 

View solution in original post

24 REPLIES 24

Should go ! Can you try it once please. If not working let me know .if it works mark the answer correct and close the thread

Not applicable

Hi, 

Is not returning any values. I changed current for request_item because I was getting an error when I tried to activate the flow.

find_real_file.png

 

var lst = fd_data.trigger.request_item.variables.your_list_collector_variable_name;

var splt = lst.split(',');

var arr=[];

for(var i=0; i<splt.length;i++)

{

var usr = new GlideRecord('sys_user_group');

usr.addQuery('sys_id',splt[i]);

usr.query();

if(usr.next())

{

arr.push(usr.name.toString());

}

}
return arr;

can you try this ?

Not applicable

Hi @Mohith Devatte 

Just tried and is not returning any value. 

can you try putting some logs ? inside for loop and and log of arr too and check please ?