Show the select box variable label instead of the value.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2025 08:49 AM
Hi All,
I just have query, we are using a multirow variable set, and we have a variable, so how do we show the variable label after selecting the choice from the select box instead of the value? We are getting data from a third party to show that is not storing in ServiceNow.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2025 11:33 PM
Hi @Ankur Bawiskar ,
There are no choices in the variable. We are not storing the variable label and value, just directly showing data that are coming from a 3rd party.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2025 11:39 PM
then this issue will always come since you are adding some option which is not present in question_choice table
Why not use Single line text and simply show A&E and E&A values?
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2025 11:54 PM
Hi @Ankur Bawiskar ,
The required is to show all the possible choices into selectbox to user will be chose according to the required.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-19-2025 11:57 PM
Please discuss this with your customer as this is not feasible.
You cannot add choices on the fly in select box
You can do this
1) just before adding the option to that select box create a new record into question_choice using GlideRecord and then addOption using g_form
In this way it will be consistent
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-20-2025 12:17 AM
Hi @Ankur Bawiskar ,
Thank you! Okay, we would be required to add the data from the 3rd party in the choice table once the form load. What happens in this case if the choice is already available in the select box? I think we can check if it's available or not and then create or update the record in the choice.
It will be approached or something else through a scheduled job. Thank!