- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2022 06:18 PM
need to extract a report that how many days it takes to fulfill a request.
can anyone help on this.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2022 09:45 PM
Hi @Arun61 ,
You can make use of duration field from sc_request table and calculate the fulfillment duration. But that field is from task table so you can either create own field for this and use calculated value as below :-
Field Type : Duration
(function calculatedFieldValue(current) {
// Add your code here
var startDate = current.closed_at.getDisplayValue();
var endDate = current.sys_created_on.getDisplayValue();
return gs.dateDiff( endDate, startDate,false); // return the calculated value
})(current);
Report :-
Please Mark My Response as Correct/Helpful based on Impact
Regards,
Gunjan Kiratkar
2X ServiceNow MVP
Community Rising Star 2022
Youtube : ServiceNow Guy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-16-2022 09:45 PM
Hi @Arun61 ,
You can make use of duration field from sc_request table and calculate the fulfillment duration. But that field is from task table so you can either create own field for this and use calculated value as below :-
Field Type : Duration
(function calculatedFieldValue(current) {
// Add your code here
var startDate = current.closed_at.getDisplayValue();
var endDate = current.sys_created_on.getDisplayValue();
return gs.dateDiff( endDate, startDate,false); // return the calculated value
})(current);
Report :-
Please Mark My Response as Correct/Helpful based on Impact
Regards,
Gunjan Kiratkar
2X ServiceNow MVP
Community Rising Star 2022
Youtube : ServiceNow Guy
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-09-2024 01:33 PM
When i go to Dictionary - New, from table "Request[sc_request]", type "Duration", label and name it, i click on the calculated Value table i cannot change the calculated check box. any ideas?