Query report - tickets onhold without response

Query report - tickets onhold without response

Hello,

We need to have a query report that shows tickets that are onhold and have not been updated for more than 7 days. I found this report online which is kind of what I want but 'Waiting for User' should be 'Onhold' and I am concerned about the last update time rather than creation time.

SELECT wo.WORKORDERID AS "Request ID" FROM WorkOrder wo LEFT JOIN WorkOrderStates wos ON wo.WORKORDERID=wos.WORKORDERID LEFT JOIN StatusDefinition std ON wos.STATUSID=std.STATUSID WHERE  ((std.STATUSNAME = 'Waiting for User') AND ((wo.CREATEDTIME >= <from_thisweek>) AND (wo.CREATEDTIME <= <to_thisweek>)))  AND wo.ISPARENT='1'

Th anks,
Matthew

                  New to ADSelfService Plus?