- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
When we used the GET with the case number to query case by id, the result is "record not found". If i changed to the case sys_id, everything works fine.
I checked and found that it's failing when we do if (gr.get('number')), which returns false, so the rest of the logic is not executed.
Has anyone faced this issue and been able to resolve it?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
as you can see it's using GlideRecordSecure so it will evaluate ACL for your API user
is that user able to see that in UI using normal table list?
💡 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 || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Hi @Ankur Bawiskar ,
It’s not working with the admin persona either, and the customer has not done any customization. The root cause appears to be the getCaseById OOB method — the line caseGr.get(id) is returning false, so the logic inside the block is not executed.
getCaseById : function(id, displayValue, selectedFields) {
this.logger.info("inside CaseDao:getCaseById id = " + id);
var caseObj = null;
if (id) {
var caseGr = new GlideRecordSecure("sn_customerservice_case");
if (caseGr.get(id)) {
caseObj = this.prepareCaseObject(caseGr, displayValue, null, selectedFields);
this.logger.debug("inside CaseDao:getCaseById caseObj = " + JSON.stringify(caseObj));
}
}
return caseObj;
}
Also, the customer has disabled the Query Rules and for query br's, I inactivated all, still the issue was observed. These have not done any customisation as well on these api's.
Do you think any another reason which can cause this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
as you can see it's using GlideRecordSecure so it will evaluate ACL for your API user
is that user able to see that in UI using normal table list?
💡 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 || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Actually we are doing it with admin persona and for admin as well its failing, removing the gliderecordsecure t gliderecord is not working as well
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
yesterday
Actually its not working for admin persona as well.
Even if I remove gliderecordsecure to gliderecord its failing
