I want to do that on oracle with ANSI JOIN:
SELECT *
FROM TICKET,
--here I have more tables that relates with TICKET
TICKET_EVO,
USER USR_CLIENT,
USER USR_SUPPORT
WHERE TICKET.ID = TICKET_EVO.ID --TICKET_EVO is child of TICKET
AND TICKET.CD_USER = USR_CLIENT.CD_USER --TICKET has the client user that opened the ticket
AND TICKET_EVO.CD_USER = USR_SUPPORT.CD_USER --TICKET_EVO has the support user that answer the client on each evolution
Thank you!
SELECT *
FROM TICKET
JOIN TICKET_EVO
ON TICKET.ID = TICKET_EVO.ID
JOIN USER USR_CLIENT
ON TICKET.CD_USER = USR_CLIENT.CD_USER
JOIN USER USR_SUPPORT
on TICKET_EVO.CD_USER = USR_SUPPORT.CD_USER