The CreatorCon Call for Content is officially open! Get started here.

Trying to create a new RITM under the one request for all users in a list collector

Bidduam
Tera Guru

I have a scenario where I want a team to be able to log a new catalog request and it will have a list of users in it via a list collector.

 

I have created a test catalog item and flow to try and get this to work, I can get a new RITM created under the original request for the number of users in the list collector, however the correct user details are not being used.

 

List collector variable:

u_user_list

Bidduam_0-1741671898943.png

 

Flow results:

Bidduam_1-1741671941299.pngBidduam_2-1741671964922.png

 

 

The actual flow:

Bidduam_3-1741671997515.png

Bidduam_4-1741672013564.png

Bidduam_5-1741672024501.png

Bidduam_6-1741672041622.png

 

Bidduam_7-1741672050948.png

 

Bidduam_8-1741672065459.png

 

Step 5 is really just for seeing the results

 

The additional comments in the RITM show:

Bidduam_9-1741672128960.png

 

As you can see the user name and user id is the same in all and not at all a user from the list collector.

 

Ideas?

 

 

 

 

 

 

1 ACCEPTED SOLUTION

@Bidduam 

Your For Each should iterate the Lookup Records and not the list collector as I informed earlier

So please update Step 3 to use iterate over Step 2

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

4 REPLIES 4

Ankur Bawiskar
Tera Patron
Tera Patron

@Bidduam 

why are you using scripted condition?

the list collector already has users as comma separated.

After Get Catalog Variables please use Lookup Records with condition as this

SysId IS ONE OF Get Catalog Variable->List collector

Then iterate these users and pick the user in the current iteration

Something like this but please enhance

In short don't iterate For Each directly on list collector, but iterate it based on Lookup Records

list collector iterate.gif

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

@Ankur Bawiskar 

Thank you, however it isn't working when I follow the process you have shown.

Unable to create serializable iterator for items: 46bd0579a9fe198101404e3929a841f5,72826bf03710200044e0bfc8bcbe5dfa,ba82abf03710200044e0bfc8bcbe5d1a,2a826bf03710200044e0bfc8bcbe5dd5,86826bf03710200044e0bfc8bcbe5d67 of class: class java.lang.String

 

 

Bidduam_0-1741675668529.png

 

Bidduam_1-1741675706378.png

 

Bidduam_2-1741675753392.png

 

Bidduam_3-1741675790798.png

 

 

 

 

@Bidduam 

Your For Each should iterate the Lookup Records and not the list collector as I informed earlier

So please update Step 3 to use iterate over Step 2

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Bidduam
Tera Guru

@Ankur Bawiskar thank you, it seems to me every time I try to use a list collector it never seems to work the same!

 

Maybe it's just me, but thank you, it is now working