We've updated the ServiceNow Community Code of Conduct, adding guidelines around AI usage, professionalism, and content violations. Read more

how to populate list of incidents created by an user

Sweety11
Kilo Contributor

Hi all,

I have created some variables into catalog item, in those incident list will be one which is of list collector type. I have a requirement that, need to display all the incident numbers which are created by a particular user.

More clear when ever I change the requested_for, that particular user incidents should display.

Can anyone help with to do it. 

Thanks in advance,

Sweety.

5 REPLIES 5

Hi,

the code looks ok to me. Make sure the client script UI Type is set to All.

Otherwise - do you get any error or what is happening? The fields are called as in the script? (requested_for, incidents_list)

Add some logging to the script include, e.g. in the while loop, something like:

while (incGR.next()) {
   gs.info(incGR.getDisplayValue());
   incList.push(incGR.getUniqueValue());
}

to check if you are getting what is expected