Unexpected Behavior: Catalog Variable Showing Another User’s Phone Number
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2 hours ago
I encountered an unexpected issue and would like your help.
I created a catalog item in ServiceNow that displays the logged‑in user's own information and allows them to edit it if necessary.
However, one user reported that the phone number shown in the catalog actually belonged to another person.
The field is populated by a variable whose default value is:
javascript: gs.getUser().getRecord().getValue('phone');
The users are on different devices, but they access ServiceNow from the same global IP address.
Interestingly, the user whose phone number appeared had logged in earlier on the same day.
This looks like a possible session mix‑up, but I'm not sure.
Is it possible for gs.getUser() to return the wrong user in this situation?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
should not occur ideally.
Did you ask that user to clear instance cache using cache.do and then logout and login again?
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Thank you for your quick reply!
I asked the user to clear the instance cache using cache.do, then log out and log back in, and that resolved the issue.
However, I'm still unsure what caused the wrong user data to appear in the first place, so I'm a bit worried about the possibility of it happening again.
If you have any ideas about the root cause, I'd appreciate any insights.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Glad to know that my approach worked
it was a cache issue. it does happen sometime
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
44m ago
💡 If my response helped, please mark it as correct ✅ and close the thread 🔒— this helps future readers find the solution faster! 🙏
Ankur
✨ Certified Technical Architect || ✨ 10x ServiceNow MVP || ✨ ServiceNow Community Leader
