- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-22-2022 12:36 PM
can i not use glide aggregate?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-22-2022 12:42 PM
What are you trying to accomplish exactly? What's the end goal once you have the aggregate count?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-22-2022 12:52 PM
I need the RITM so instead of GlideRecord i wanted to go ahead with GlideAggregate.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-22-2022 12:54 PM - edited 11-22-2022 12:55 PM
The code I provided will give you that and also let you access the RITM details.
var ritm = new GlideRecord('sc_req_item');
ritm.addEncodedQuery('active=true^RLQUERYsc_task.request_item,=00^active=true^ENDRLQUERY');
ritm.query();
gs.print(ritm.getRowCount());
while(ritm.next()){
gs.print(ritm.number);
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-22-2022 01:17 PM
I would avoid dot-walking in an encoded query.