Regarding the control of the display of choices in the list collector variable

Koki Sugimori
Tera Contributor

We are currently creating two variables (List Collector① and List Collector②) with catalog items.

 

As an example, I would like to achieve the following by setting the same A, B, C, D, and E options for list collectors① and ②.
Does anyone know of a solution?

 

[Set values for list collectors① and ②]
 List table: Question Choice[question_choice].
 Reference qualifier: unset

 

【Question】

Referring to the image, please tell me how to make sure that what is selected in the list collector① cannot be selected in list collector②.

KokiSugimori_0-1736474175834.png

 

Do I need to edit the current Reference qualifier? Or do I need to create a new catalog client script?

 

Can anyone assist me on how to implement the above?
Thank you in advance.

1 ACCEPTED SOLUTION

@Koki Sugimori 

try this

javascript: 'sys_idNOT IN' + current.variables.1stVariableName;

also add variable attributes

ref_qual_elements=1stVariableName

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

@Koki Sugimori 

you already raised a question for something similar yesterday

Any reason to raise a duplicate question? I already provided solution there

How to show/hide choices for list collector variables 

you can handle it in existing ref qualifier

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

@Ankur Bawiskar 

Thank you for your answer.

 

Can you solve the problem with what you answered yesterday as shown in the image below?

How to show/hide choices for list collector variables

 I tried with PDI and could not do it.

KokiSugimori_0-1736484246097.png

 

I apologize if my knowledge is insufficient.

@Koki Sugimori 

try this

javascript: 'sys_idNOT IN' + current.variables.1stVariableName;

also add variable attributes

ref_qual_elements=1stVariableName

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 very much.


I was able to try and implement this.

I have approved this as a solution.