Assistance with Report - SQL Query to populate data in feilds
I have a report that pulls the table in Service Desk. The label for APPROVERS and APROVAL is there but the data is blank:
SELECT HD_TICKET.ID,
S.FULL_NAME AS SUBMITTER_NAME,
HD_TICKET.PARENT_ID,
HD_TICKET.IS_PARENT,
HD_TICKET.TITLE,
HD_TICKET.SUMMARY,
AP.FULL_NAME,
HD_TICKET.APPROVAL,
HD_TICKET.APPROVAL_NOTE,
IF(HD_TICKET.HD_USE_PROCESS_STATUS and HD_TICKET.IS_PARENT,
HD_SERVICE_STATUS.NAME, HD_STATUS.NAME) AS STATUS_NAME,
O.FULL_NAME AS OWNER_NAME,
HD_TICKET.CUSTOM_FIELD_VALUE1,
HD_TICKET.CUSTOM_FIELD_VALUE2,
HD_TICKET.RESOLUTION,HD_TICKET.CUSTOM_FIELD_VALUE0 FROM HD_TICKET LEFT JOIN USER S ON (S.ID = HD_TICKET.SUBMITTER_ID) LEFT JOIN USER AP ON (AP.ID = HD_TICKET.APPROVER_ID) LEFT JOIN HD_SERVICE_STATUS ON HD_TICKET.HD_USE_PROCESS_STATUS and HD_TICKET.HD_SERVICE_STATUS_ID and HD_SERVICE_STATUS.ID = HD_TICKET.HD_SERVICE_STATUS_ID LEFT JOIN HD_STATUS ON (HD_STATUS.ID = HD_TICKET.HD_STATUS_ID) LEFT JOIN USER O ON (O.ID = HD_TICKET.OWNER_ID) WHERE (HD_TICKET.HD_QUEUE_ID = 4) ORDER BY ID
Answers (2)
I did find that the information i need is not in that table. Since the Approval process is part of a process. here is the info from Quest support but I don't have enough SQL skills to write the query:
Indeed, the process field is different from the regular field. For process, the table for app-rover information is on a different table, which is HD_TICKET_APPROVAL.