SysID of a record

asher14
Tera Contributor

Hello,

Im still new in coding and having some trouble. 

I am currently building a display business rule and client script. In the advance tab in the display BR I need to query the gliderecord to get the sysid of the field "other" (which is 'u_category') from another reference table('u_tracked_table')

 

Heres what I have so far but I am blocked:

 

var gr = new GlideRecord('u_tracked_table');

gr.addQuery('sys_id', u_category.sys_id);

gr.query();

8 REPLIES 8

Shubham Singh
Mega Guru

Hi @asher14 

 

The requirement is not clear in your question. Maybe you can explain it properly so we can help you here!

 

Thanks!

Hello,

thank you for replying with feedback. It is a two part requirement and I want to focus on part 1 first because I believe I can explain a better. 

 

How do i create a gliderecord to the reference table that gets the sys_id of a field on a record. The field name is called Other however in the backend on that table it is name 'u_category'. 

 

Hi @asher14 

 

So what I understood here is you need sys_id of a field present on another table.


Here if you need sys_id of field then do the GlideRecord on the sys_dictionary table and use EncodedQuery as per need.

 

Thank you!

 

Please mark this response as correct and helpful if it helps you ✔️👍

Mohan raj
Mega Sage

Hi @asher14,

 

Don't understand your what your trying asking, can you elaborate in details