- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-21-2016 11:45 AM
We have to run some reports based on incoming tickets for an assignment group by month.
I don't see an OOTB field on Incident table which captures Assignment date/time stamp.
There is only opened field, but the requirement is on assigned to group date/time stamp.
Please help on same.
Thank you
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-23-2016 06:09 AM
For the BR script, if the Assignment Group ever gets blanked out, your "if" statement will skip that event. If that's not what you meant, you may need to remove the "if".
For retroactively filling in the new column value, you'd use GlideAggregate like below (not tested):
var ga = new GlideAggregate('sys_audit');
ga.addAggregate('MAX', 'sys_created_on');
ga.groupBy('documentkey');
ga.addQuery('tablename', 'incident');
ga.query('fieldname', 'assignment_group');
while (ga.next()) {
var sys_id = ga.documentkey; // sys_id of incident
var assigned_on = ga.getAggregate('MAX', 'sys_created_on'); // last time assignment_group changed
var gr = new GlideRecord('incident');
if (gr.get(sys_id)) { // find incident record
gr.u_assigned_on = assigned_on; // set value
gr.update();
}
}
Now that you're capturing this value in a field, you won't need that as a metric any more but use if for other metrics such as
- Duration between Opened and Last Assigned
- Duration between Last Assigned and Resolved
These in conjunction with reassignment_count and other metrics may provide valuable insights.
Again, if you ever need to see all reassignment history, you can use the very first solution I provided using sys_audit,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-21-2016 12:08 PM
Please see my answer to the post Is there a way to see who has been assigning incidents to individuals (based on new unassigned ticke... You can use a similar filter, but use Field name is assignment_group.
Hope this helps.
Please feel free to connect, follow, mark helpful / answer, like, endorse.
John Chun, PhD PMP ![]() | ![]() |
Winner of November 2016 Members' Choice Award

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-21-2016 12:13 PM
See metrics for this. You can create your own metric definition.
Metric Definition Support - ServiceNow Wiki
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-22-2016 07:29 AM
Hello Abhinay,
Thank you, I referred this section it is really helpful.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-22-2016 07:46 AM
As I mentioned you will have to consider building your own metric definition and pulling the reports on them.