Report commonly used K1000 ticket categories
Is it possible to run a report showing the top 5-10 ticket categories that have been chosen and the number of tickets for each one?
Answers (1)
The following will give you ticket counts, sorted by queue then category.
SELECT HD_QUEUE.NAME as 'Queue',
HD_CATEGORY.NAME as 'Category',
count(HD_TICKET.id) as 'Count'
FROM HD_QUEUE
INNER JOIN (HD_TICKET
INNER JOIN HD_CATEGORY ON HD_TICKET.HD_CATEGORY_ID = HD_CATEGORY.ID)
ON HD_QUEUE.ID = HD_TICKET.HD_QUEUE_ID
Group BY HD_QUEUE.NAME, HD_CATEGORY.NAME
ORDER BY HD_QUEUE.NAME, HD_CATEGORY.NAME;
If you are looking for a single queue, you can add that as a where condition.
For the top 5 from any queue, you would change the order by to
order by count(HD_TICKET.id) desc limit 5
Getting the data you are seeking will depend on exactly how your Service Desk module is configured.
Comments:
-
Thank you very much, this is exactly what I needed - jbunnell 11 years ago