- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-07-2018 11:51 AM
How do you get the sys_id of a reference field via server script?
I tried the following, but I am getting the displayed name instead of the sys_id.
'"table".getValue('name')'.
Solved! Go to Solution.
- Labels:
-
Scripting and Coding

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-07-2018 01:10 PM
If Assignment Group is a reference field, I would just do current.assignment_group. I would name add name (current.assignment_group.name), which will give me the display value.
Please mark this response as correct or helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-07-2018 12:28 PM
You can use current.reference_feild_name
Please mark my response as correct and helpful if it helped solved your question.
-Thanks

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-07-2018 12:39 PM
Hi,
Try .getUniqueValue();
Thanks,
Nithish

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-07-2018 01:10 PM
If Assignment Group is a reference field, I would just do current.assignment_group. I would name add name (current.assignment_group.name), which will give me the display value.
Please mark this response as correct or helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎09-11-2018 10:58 AM
Thank you this worked!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-15-2025 12:25 AM
while(gr.next())
gr.ref_field_name.getRefRecord().getUniqueValue()