- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-21-2022 05:04 AM
When displaying a Reference Field C as a drop down, how can I get the values to be filtered based on Fields A and B ?
I have 3 Reference fields. Field C values are dependent on what is chosen for Field A and B. I have created a Reference Qualifier to handle the filter for Field C. When changing the values of Field A and/or B, Field C automatically (without pressing Save/Update button) shows the correct new values based on these Fields A and B. All work great, as shown below.
Now if I change Reference Field C to be a drop down.
Now when I change the values for Field A and Field B, Field C (still reference field) does not refresh automatically (without pressing Save/Update button) with a new list of Values.
When displaying a Reference Field C as a drop down, how can I get the values to be filtered / refresh automatically based on values selected for Fields A and B ?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-21-2022 05:33 AM
Hi,
I would recommend keeping field C as reference only and not drop down.
Reason being if the table is huge then it won't be a good user experience and user might have to scroll down to select the value.
Also advanced ref qualifier won't work on drop down field as per my understanding.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-21-2022 05:21 AM
Hi Marc,
You need to set up an advanced reference qualifier to provide the data. Depending on your requirements is can be either dynamic or advanced. Here's the link to the documentation on that.
Hope that helps.
:{)
Helpful and Correct tags are appreciated and help others to find information faster
:{)
Helpful and Correct tags are appreciated and help others to find information faster
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-21-2022 05:27 AM
That is what I did. Works when Field C is still just a default reference field.
Does not work when you switch the reference field into a drop-down reference field. Is there some trick to make this work with a drop-down reference field?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-22-2022 09:59 AM
Hi Marc,
As far as I know, you can have a reference field or a drop down. If you REALLY MUST have a drop down then you may have to resort to on change client scripts for the two other fields and have the script issue an AJAX call to the function that picks the acceptable values. It should return both the label and sys_id. From there your script will replace the choices in the list.
Hope that helps.
:{)
Helpful and Correct tags are appreciated and help others to find information faster
:{)
Helpful and Correct tags are appreciated and help others to find information faster
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-21-2022 05:33 AM
Hi,
I would recommend keeping field C as reference only and not drop down.
Reason being if the table is huge then it won't be a good user experience and user might have to scroll down to select the value.
Also advanced ref qualifier won't work on drop down field as per my understanding.
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader