The CreatorCon Call for Content is officially open! Get started here.

Need assistance with variable attribute

Community Alums
Not applicable

Hi,

Scenario: I have a catalog item with a reference type variable referring to- the table cmn_department. I want to show the name of Department, its CI Group, and CI Group manager to the end-user.

 

Relationship:

1) The department names stored in cmn_department table (reference table of variable, CI Group names not present in this table)

2) The departments and Its respective CI Group are stored in the cmdb_ci_group table. (CI Group field is reference field)

3)The CI Group and CI Group manager relationship is stored in the sys_user_group table.

 

Question: Is it possible to show the name, CI Group, and CI Group manager to the end user if data available in multiple tables for the catalog item?

Example what we want:

Amit136581_0-1695037514938.png

can anyone please guide me, how we can achieve it.  Thanks!

 

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

@Community Alums 

you can show data only from the referenced table but not from other table.

the closest you can do is to set a text variable with the values for CI Group and CI Group manager on department selection

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

6 REPLIES 6

Community Alums
Not applicable

Hi @Community Alums 

 

In which way you want show all these field can you please describe in detail or provide me the screenshot.

 

Mark the comment as a correct answer and also helpful if this has helped to solve the problem.

Krishna Sharma

 

 

Community Alums
Not applicable

Hi @Community Alums ,

 

I want to show like this to end user

Amit136581_0-1695037473825.png

 

Sanjeet_Choudha
Tera Expert

Hi @Community Alums ,

Try this solution and mark helpful if this will help you.

https://www.servicenow.com/community/itsm-forum/list-attributes-beyond-name-for-user-reference-fields/m-p/591035 

Vishal Birajdar
Giga Sage

Hi @Community Alums 

 

Assuming CI group field is present on cmn_department table

 

you can use below attribute

 

ref_auto_completer=AJAXTableCompleter,ref_ac_columns_search=true,ref_ac_columns=ci_group,ci_group.manager.name,ref_ac_display_value=false

//user your backend name's

 

Vishal Birajdar
ServiceNow Developer

I know one thing, and that is that I know nothing.
- Socrates