I need to get the locations parent which is the Region. Its not pulling for me.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-21-2022 11:29 AM
This code gives me the location.
I tried modifying to this to get the parent:
Here is the record:
Any help is always appreciated.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-21-2022 11:37 AM
Hi @Allen12 ,
Not sure why are you trying to use GlideRecord in a client script, but it is highly recommended not to use gliderecord in client side scripting.
Exhibit A:
sing Glide record in client script
So instead of GlideRecord, you can use GlideAjax, the GlideRecord portion you can place inside a function in a Script include and just make a callback using getXMLAnswer.
Ex:
https://www.servicenow.com/community/developer-articles/getxmlanswer-vs-getxml/ta-p/2307589
Aman Kumar
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-21-2022 11:39 AM
You'll need to use GlideAjax for this.
Examples/Cheat Sheet provided here
https://www.servicenow.com/community/developer-articles/glideajax-example-cheat-sheet/ta-p/2312430