
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2017 07:55 AM
Hello
I trying to keep this simple and align with ServiceNow OOTB features. Currently in ServiceNow on an Incident Record there is Category (string) and Subcategory (reference) fields. I am creating a Service Portal/Catalog form request to get End User values and directly create an Incident record; standard or basic Help Desk form "I have a problem and need to create an Incident". So my thinking was to match to the exact current "Category" and "Subcategory" field values of our ServiceNow instance, that way the values stay consistent with the values on the service catalog form vs. creating two static choice string fields and just passing the values to the incident record; more maintenance keep the form up to date with Incident record field values.
I am having two issue.
1.) I am struggling in getting the string values of the 'Category' field from the Incident table to appear on my catalog from. I am using a reference field type on my catalog form but obviously the Category field on the Incident table is just a string box, and I am not able to find an appropriate table to reference, which maybe reason why it is not working. So how do I reference this field from the Incident table? Or am I just going to need to create a choice field with the same values as on my Incident Category column field?
2.) Not seeing how to make the Subcategory field dependent on Category field selection like it is done within the Incident record. I found the following article, so do I still need create a script include to make this functionality work on the catalog form request? Or is there already an Out-of-the-box script include for the this function? http://wiki.servicenow.com/index.php?title=Adding_Dependent_Reference_Variables#gsc.tab=0
______________________________________________________________________________________________________________________________
Fig #1
______________________________________________________________________________________________________________________________
Fig #2
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-20-2017 04:17 AM
You should just use Select Box for the Category/Subcategory on the record producer.
I recently ran into a problem where I couldn't filter subcategory based on category on Service Portal. This link helped with that: Dependent Variables in Service Portal do not reload on values when changed
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2017 08:06 AM
Wesley,
If your Incident.Category field is a string/drop-down, then you want to choose "Selectbox" on your category variable (within your catalog item). When you do that, you will get the Choice (sys_choice) table and field selections. That lets you say, "Please reference the Category field on the Incident table so I can reuse their values".
That's why the 2nd screenshot you have is working better than the first.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2017 08:44 AM
Hi Cary,
Understand what you are saying (I think) but still confused on using the sys_choice table as my "Choice Table" option, because there is no match to the "Choice Field" (Fig #3). It makes sense to me if the Category field (OOTB) on Incident table was referenced field to a small table like Subcategory is. But Category is just string field with a few choices. It makes me wonder why ServiceNow made this field only a string with choices vs. a reference field to the sys_choice table (Fig #4).
______________________________________________________________________________________________________________________________
Fig #3
______________________________________________________________________________________________________________________________
Fig #4
Thank you,
-Wesley
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2017 10:22 AM
Sorry for the confusion! You want to use the Incident table, not the Choice (sys_choice) table.
Choice Table: Incident
Choice Field: Category

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2017 10:35 AM
Hi Cary,
Ah, that makes sense now. Working great now. So problem #1 has been resolved. Any thoughts on how to handle problem #2?
-Wesley