- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2023 12:27 PM
Hi,
I am trying to access the value of the Duration field displayed on the Major Incident Workbench. Does anyone know what this field is named?
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2023 01:19 PM
I dont see any mi_duration field in incident table.
I think, mi - (stands for) - metric instance and it's a field from database view.
Hope that helps.
Kind Regards,
Swarnadeep Nandy

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2023 12:31 PM - edited 08-16-2023 12:32 PM
Hello @tomlm13,
The Duration field displayed on the Major Incident Workbench is a calculated field that shows the total time elapsed since the major incident was created until it was closed or resolved. The field name for this duration is mi_duration. You can access this field by using the GlideRecord API to query the sn_major_incident table and get the value of the mi_duration field. For example:
// Query the sn_major_incident table for a specific major incident number
var gr = new GlideRecord('sn_major_incident');
gr.addQuery('number', 'MI0000001');
gr.query();
// Get the value of the mi_duration field
if (gr.next()) {
var duration = gr.mi_duration;
// Do something with the duration value
}
I hope this helps.
Kind Regards,
Swarnadeep Nandy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2023 01:07 PM
I am attempting to access this value from an email client template via the following line:
${incident_alert.source_incident.mi_duration}
This does not appear to work, do you have any suggestions. My end goal here is to get a current duration value to include in outage communication tasks.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-16-2023 01:19 PM
I dont see any mi_duration field in incident table.
I think, mi - (stands for) - metric instance and it's a field from database view.
Hope that helps.
Kind Regards,
Swarnadeep Nandy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-30-2025 09:42 AM
Were you ever able to get this to work? I am trying to get the same thing on my comms. Thanks!