I need to be able to clearly report on what my technicians are doing. I can see how many calls they log/close, but not how often they touch/update a call, so if possible include Edit call, Add notes, send email, etc.
I've found the below query previously shared, however I'm not sure it works correctly as I've ran it for today and none of the actions taken by me today showed on the report
If I could get an update versions, ideally it would have the same fields, without the grouping, but with guidance on what the different "Operations" mean please?
SELECT au.first_name "Technician" ,wo.WORKORDERID "Request ID",aau.FIRST_NAME "Requester",wo.TITLE "Subject",std.STATUSNAME "Request Status",Longtodate(wo.CREATEDTIME) "Created Time",Longtodate(wo.COMPLETEDTIME) "Completed Time",
ti.FIRST_NAME "Assigned Technician",au.first_name "Technician",
LONGTODATE(OPERATIONTIME) "OPERATIONTIME",
(woh.Operation) "Operation" FROM WorkOrder wo
LEFT JOIN SDUser sdu ON wo.REQUESTERID=sdu.USERID
LEFT JOIN AaaUser aau ON sdu.USERID=aau.USER_ID LEFT JOIN WorkOrderStates wos ON wo.WORKORDERID=wos.WORKORDERID LEFT JOIN SDUser td ON wos.OWNERID=td.USERID LEFT JOIN AaaUser ti ON td.USERID=ti.USER_ID LEFT JOIN StatusDefinition std ON wos.STATUSID=std.STATUSID left join workorderhistory woh on wo.workorderid=woh.workorderid left join aaauser au on woh.operationownerid=au.user_id where (wo.ISPARENT='1') and wo.CREATEDTIME >= <from_lastweek> AND wo.CREATEDTIME <= <to_lastweek> order by 1
Database Name = Microsoft SQL Server
Current Build = 11005