How to display the value of another column for a reference field

Kunal W
Tera Contributor

Hello,

We have created one new reference field called 'Protocol' referring to the 'Study' table (extended from cmdb_ci). We have changed the list layout of the lookup table which shows only correlation_id (one of a column on the Study table) and one more field. When we select any correlation_id it is showing Study name on the field instead of correlation_id. Is there any way we can change the value displayed on the field? Currently, it is showing the value of the Name column but I want the value to be shown from the correlation_id column. Let me know if you need more info on this.

 

Thank you.

3 REPLIES 3

Joe S1
Kilo Sage

Hello @Kunal W 

 

You'll need to create a Dictionary Override on the Correlation ID field at the cmdb_ci class that overrides the Display value for the 'Study' table. This will make the Correlation ID the display value for the 'Study' table.

JoeS1_0-1685543499067.png

 

JoeS1_2-1685543541327.png

 

JoeS1_3-1685543557821.png

 

 

Kunal W
Tera Contributor

Hello @Joe S1 

 

Thank you for your suggestion, I have made changes and it was working. But it creates an issue on another table. We have a relationship table where studies, devices, and everything is related. So when we try to search study there by study name it is not showing any results because it is checking for correlation_id and not for study name by default. This is the one issue I found there can be many. Is there any way where we can only configure for that specific protocol field?

 

Thank you

Unfortunately, no. The display value of a reference field is controlled at the table level, whichever field you choose to use as your display value ServiceNow will use that field across the instance on any reference fields you have.