How to add Variables to List View on Task Table?

Community Alums
Not applicable

On the 'My Groups Work' module, we have been asked to add one of the catalog variables to the list view to help our Server team organize their work intake.  I can see and add all sorts of extended table fields, but I can't seem to find the variables.  When I switch and go to the Requested Item table list view, I can see and add variables there no problem.  It is fairly straightforward - add variables.c35ad1efdb34c010993f5f774896193e as an element in list configuration and there is the variable.  When I go back to task table, I can see when I add an one of the extended fields on the Requested Item table the syntax for the element is ref_req_item.field  and this works just fine for any field, but when I use ref_req_item.variables.c35ad1efdb34c010993f5f774896193e nothing shows up.

Anyone able to help me?

1 ACCEPTED SOLUTION

Community Alums
Not applicable

Hi Dirk,

I meant to come back here and add the response to the HI ticket but I forgot.

Here is the response from the HI Agent:

- Adding a catalog item variable to the list is not a good idea because not all the catlog items will have the variable used in them.
- To explain this better, let me take an example. The variable "Enter Full name of the AD Group" is added to the list view of "sc_task" and "task". The "task" list contains request, requested items, task records and "sc_task" list contains task records. Not all the catalog items will have the "Enter Full name of the AD Group" variable.
- The following is the hierarchy in which the tables are extended.
task - sc_request - sc_req_item - sc_task
- The variables of the catalog item are available only from the "sc_req_item" table. That is the reason the variables and values associated to the variables are present on "sc_req_item", "sc_task" tables but not on "task" and "sc_request" tables.

I've gone ahead and added a new Idea on the Idea Portal:

https://community.servicenow.com/community?id=view_idea&sysparm_idea_id=a41741f2db9ee850d5c4d9d968961925&sysparm_idea_table=x_snc_com_ideation_idea&sysparm_module_id=enhancement_requests

I will most likely go with Ankur's workaround and just map the variable values to a field on the Catalog Task table so that these will be visible.

Thanks,

Dustin

 

View solution in original post

10 REPLIES 10

DirkRedeker
Mega Sage

Hi

Your question is very interesting, and I have one to you upfront.

How do you add the variables to the RITM List View? I just tried to do so, and I also find the "variables[+]" entry in the slushbucket to add the field to the list, but they are empty in the list and also any related fields are hidden, when added.

Can you please supply some screenshots here, where you achieved to add the variables of RITMs in the List view. Would be a pleasure for me.

Thanks & BR

Dirk

Community Alums
Not applicable

Sure thing.

1. Go to the item_option_new table and get the sys_id of your variable to add.

2. Go to the sys_ui_list table and open the list you want to add the variable to.  For me, I added it to sc_req_item list.

3. In the List Elements section, add a new element, and use the syntax variables.sys_id like the screenshot below.

4. Open your list, use the gear icon to move the new variable you added, save, then refresh and you will see the variable on the list.

Let me know if you get stuck on any of these 4 steps.

find_real_file.png

Hi @Dustin Watkins 

Thanks so much for an answer give in your question!

That works perfect, and I did not know that this is even possible. 

That may come in handy in some scenarios.

AWESOME!

Thanks a lot & BR

Dirk

DirkRedeker
Mega Sage

Hi

Now knowing, how I can add Catalog Variables on the "RITM" List, I replayed your scenario and tried with the [sc_task] table to show variables in the list, by dot-walking like you suggested:

request_item.variables.d644b36707229c100e26f48f7c1ed009

But also with NO luck. As you wrote, the field is NOT shown on the list, and not even visible in the Slushbucket. Other fields from the RITM can clearly by added to the List.

One thing, that I saw during testing & investigation is, that on the RITM List, the Variable in the Slushbucket is not shown like variables.d644b36707229c100e26f48f7c1ed009  but as "variable name/question" instead.

This shows, that ServiceNow UI can identify the "Name" of the variable while on the "RITM" list.

Maybe this is something extra that is implemented in the UI. Would not be the first "special" for Catalog Stuff.

When dot-walking to that table (comming from another table), maybe the UI does not recognize, that you just want to go that same path, like comming from the RITM List directly.

After all my tests I did not, I guess this is not possible as all.

Do get 100% sure, we need to get some ServiceNow Developer, or open a HI ticket for it.

Let me know if that answers your question and mark my answer as correct and helpful.

Thanks for this Knowledge!

BR

Dirk

Hi

Do you have an update on this question? Were you able to sort it out?
If you were able to solve your issue, just let me know and mark the best answer as correct and helpful.
This will close this thread and help others to benefit from the outcome.

Thanks & BR
Dirk