- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-28-2019 01:10 AM
How can we pass reference field columns to $sp.getRecordDisplayValues?
I tried with below code but doesn't work.
var obj = {};
var columnsToGet = 'number,agency.number,agency.name';
$sp.getRecordDisplayValues(obj, gliderecord, columnsToGet);
where agency is a reference field. Number is populating since it is part of current table but other fields are not populating. Please advise.
Solved! Go to Solution.
- Labels:
-
Service Portal Development
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-28-2019 02:09 AM
Thanks for your support. But, I somehow made it work through the existing code itself.
Instead of item.agency.name,I used item["agency.name"]. My bad, we can not directly fetch values of keys with such names abc.xyz by simply dot-walking. Instead, we need to fetch the same by passing it as a key.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-28-2019 02:22 AM
Good one.
My bad i did not think from that way. you are correct here.
mark your answer as correct and close this thread.