Populate List collector catalog item variable on the basis on another variable
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2024 08:04 AM
Hi,
I have below requirement,
Catalog item A contains 2 variables A1 and A2.
A1 is of type Lookup select box referring to table B.
Table B has 2 columns B1 and B2.
Values from B1 should be shown in Variable A1 and it's working fine also with the help of Look Up field value which is set to column B1.
Now requirement is that variable A2 which is of List collector Type should show values from B2 where A1 and B1 are same. Problem here is that in List collector type field we do not have an option to give look up field name and I am not able to specify that it should show values from B2.
Please suggest how A2 will show values from B2, right now it's showing duplicate values from B1, but not unique values from B2 when A1 and B1 are matching.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2024 08:47 PM
list collector variable holds the sys_id of record and shows the display value column of the record.
Try to replace the display value and test.
Please mark this response as correct and helpful if it helps you can mark more that one reply as accepted solution
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2024 06:09 AM
Hi @AshishKM ,
Display value can't be set to true for any other column as this Table 'B' is like common config table used for many catalog items and both B1 and B2 columns are of type string only.
I tried different ways but nothing works for me.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-10-2024 09:32 PM
Hi @vivek72
Please refer this video regarding to list collector:-
https://www.youtube.com/watch?v=5rT8ZeKbYck
Please mark reply as Helpful/Correct, if applicable. Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2024 06:15 AM
Hi @Service_RNow , Checked it as well, couldn't get it working for my use case.
Tried with On change Client Script and Script include also, nothing works .
Took help from https://www.servicenow.com/community/developer-blog/dynamically-set-list-collector-on-change-of-vari... but in my case answer is coming as NULL
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-11-2024 06:41 AM
Hi Guys,
Thanks a lot for trying to help me out here, it almost worked with the help of steps explained in below URL
Only question is list collector values are auto populating but I need user to select values.
When Dependent variable changes, list collector field should be updated with values in list instead of populating all values.
Please suggest how shall we make this modification.