/build/static/layout/Breadcrumb_cap_w.png

how to pull a report on tickets 'created by ' ?

what sql detail collects this data, how do I create a report to get the   CREATED BY  info

2 Comments   [ + ] Show comments
  • great !! works great... how do I specify a date range, like Monday oct 3rd thru the 5th ??? - 2Leo 7 years ago
  • You would change the line referencing timestamp to something like

    AND timestamp between '2016-10-3' and '2016-10-6'

    The MySQL converts the dates to timestamps with the time portion 00:00:00. To include tickets on the 5th, you need to set the range through to 2016-10-6 00:00:00. - grayematter 7 years ago

Answers (1)

Answer Summary:
Posted by: grayematter 7 years ago
5th Degree Black Belt
2

Top Answer

You get the CREATED BY info from the HD_TICKET_CHANGE table, just filter on the description field as below.  This should get you started.

SELECT 
    USER.USER_NAME,
    COUNT(HD_TICKET_CHANGE.HD_TICKET_ID) AS count
FROM
    HD_TICKET_CHANGE
        INNER JOIN
    USER ON USER.ID = HD_TICKET_CHANGE.USER_ID
WHERE
    description LIKE 'Ticket Created%'
        AND timestamp > DATE_SUB(NOW(), INTERVAL 7 DAY)
GROUP BY USER.USER_NAME
ORDER BY USER.USER_NAME

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ