How to generate a report showing users from specific group logins per month?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2025 08:08 AM
Hi All,
I'm trying to generate a report showing how many times users from a specific group logged into the ServiceNow portal over the course of a month. I need to run this report periodically. Any ideas or suggestions would be appreciated.
Thanks,
Praveena. K

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2025 08:31 AM
Check if any data is available in sp_log table which is Service Portal Logs Entries table.
However your requirement looks like a custom one and report might not be possible OOB.
Accept the solution and mark as helpful if it does, to benefit future readers.
Regards,
Sumanth
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2025 08:47 AM
for this you will have to check couple of system tables
This is not a straight forward requirement
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-13-2025 08:48 AM
Hi @Praveena KKS ,
you can create a Database view between sys_audit and sys_user tables
where class used
sa.documentkey=su.sys_id && sa.fieldname='last_login'
Create a Script include with Sandbox enabled true
var GroupMemberUtils = Class.create();
GroupMemberUtils.prototype = {
initialize: function() {},
getGroupMembers: function(id) {
var members = [];
var grpMemGr = new GlideRecord('sys_user_grmember');
grpMemGr.addEncodedQuery('group=' + id);
grpMemGr.query();
while (grpMemGr.next()) {
members.push(grpMemGr.getValue('user'))
}
return members;
},
type: 'GroupMemberUtils'
};
create the report on DBV
filter used
javascript:new GroupMemberUtils().getGroupMembers('Put SySID of your Group')
You got the idea
you can extend this as per your requirement
Please mark my answer as helpful/correct if it resolves your query.
Regards,
Chaitanya