Salut a tout le monde j'ai un petit probleme avec un code hql je voudrais asvoir comment faire pour "convertir" une requette msql en hql
Code:
SELECT
ID ID_JOB,
SEQ ID,
(SELECT DISTINCT VALUE JOB_GROUP FROM DC_LOGGING WHERE ID = AA.ID AND SEQ = AA.SEQ AND POS = AA.POS AND NAME = 'JOB_GROUP') JOB_GROUP,
(SELECT DISTINCT VALUE JOB_NAME FROM DC_LOGGING WHERE ID = AA.ID AND SEQ = AA.SEQ AND POS = AA.POS AND NAME = 'JOB_NAME') JOB_NAME,
AGENT HOST,
TIME START_DATE,
(SELECT DISTINCT VALUE RETRY FROM DC_LOGGING WHERE ID = AA.ID AND SEQ = AA.SEQ AND POS = AA.POS AND NAME = 'RETRY') RETRY,
TYPE,
TYPE_DESCRIPTION,
ERR ERROR,
ERROR_DESCRIPTION,
(SELECT DISTINCT VALUE MESSAGE FROM DC_LOGGING WHERE ID = AA.ID AND SEQ = AA.SEQ AND POS = AA.POS AND NAME = 'MESSAGE') MESSAGE
FROM
(SELECT DISTINCT A.ID, A.SEQ, A.POS, A.AGENT, A.TIME, A.TYPE, T.DESCRIPTION TYPE_DESCRIPTION, ERR,
E.DESCRIPTION ERROR_DESCRIPTION FROM DC_LOGGING A, DC_LOG_TYPE T, DC_ERRORS E
WHERE A.ID = 66656 AND A.POS = 'T' AND A.TYPE = T.ID_LOG_TYPE AND A.ERR = E.ID) AA ORDER BY SEQ
le probleme se pose au niveau du
Code:
....
FROM
(SELECT DISTINCT A.ID, A.SEQ, A.POS, A.AGENT, A.TIME, A.TYPE, T.DESCRIPTION TYPE_DESCRIPTION, ERR,
E.DESCRIPTION ERROR_DESCRIPTION FROM DC_LOGGING A, DC_LOG_TYPE T, DC_ERRORS E
WHERE A.ID = 66656 AND A.POS = 'T' AND A.TYPE = T.ID_LOG_TYPE AND A.ERR = E.ID) AA ORDER BY SEQ
je sais pas comment interpreter " select from(selec...) merci d'avance de votre aide