You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This script tracks the time it took to assign a task (like an Incident, Change, etc.) by calculating the difference
2
+
between when the record was created and when it was assigned (assigned_to was set).
3
+
It checks if the assigned_to field has changed and is not empty.
4
+
If it's the first time the record is being assigned (u_assignment_time is empty), it captures the current time.
5
+
It then calculates the time difference between when the record was created and when it was assigned.
6
+
This time difference (in minutes) is stored in a custom field u_time_to_assign.
7
+
The goal is to track how long it took for the record to be assigned after creation
8
+
9
+
10
+
## While this is possible to do via Metrics in ServiceNow (https://www.servicenow.com/docs/bundle/xanadu-platform-administration/page/use/reporting/concept/c_SampleFieldValueDurationScript.html),
11
+
## the script is being provided to potentially solve some edge cases.
0 commit comments