Query Report

Query Report

Hi,

We Used the below query to fetch the details of time spent by each groups assigned to the ticket.

select woa.workorderid "RequestID",

qd1.QUEUENAME  "From Group",

qd2.QUEUENAME  "To Group",

cast((wog.timespent/60) as varchar(20)) +':'+cast((wog.timespent % 60) as varchar(20)) "Time Spent (hrs)" from workorder wo

left join wo_assessment woa on wo.workorderid=woa.workorderid

inner join WO_GROUP_INFO wog on woa.assessmentid=wog.assessmentid

LEFT JOIN QueueDefinition qd1 ON wog.groupid=qd1.QUEUEID

LEFT JOIN QueueDefinition qd2 ON wog.nextgroupid=qd2.QUEUEID where wo.CREATEDTIME >= <from_yesterday> AND wo.CREATEDTIME <= <to_yesterday> order by 1

Now we need customized report as,
1. Time spent need to calculate for specific groups.
2. The above query returns the time spent in hrs basis, we need to align this query as minutes based.
3. We need a format like below mentioned,

Ticket ID Request type Created Time Group1 Time Spent Group2 Time Spent Total time spent


Regards,
Karthikeyan

                  New to ADSelfService Plus?