Only Select Specific Technicians on a Report
I have this as my SQL statement and it works great but can't seem to get it to work for just specific technicians
SELECT USER.USER_NAME as OWNER, count(HD_TICKET.ID) as NUMBER_OF_TICKETS,
ROUND((AVG(TIMESTAMPDIFF(DAY,
HD_TICKET.CREATED,
TIME_CLOSED)
)), 1) AS "Avg Days Open"
from HD_TICKET
JOIN HD_STATUS on (HD_STATUS.ID = HD_TICKET.HD_STATUS_ID)
LEFT JOIN USER on (USER.ID = HD_TICKET.OWNER_ID)
where HD_STATUS.STATE ='closed'
and HD_TICKET.TIME_CLOSED > DATE_SUB(NOW(), INTERVAL 30 DAY)
and HD_TICKET.HD_QUEUE_ID in (1) /*add queue numbers here*/
GROUP BY OWNER
2 Comments
[ + ] Show comments
-
Hard code the names - scarpent 7 years ago
-
I have done this in the past for other reports but for some reason on this one I keep getting SQL error message with multiple names and if I use 1 name I get zero data - scarpent 7 years ago
-
Post your query that fails, please. - chucksteel 7 years ago
Answers (1)
Please log in to answer
Posted by:
chucksteel
7 years ago