Hibernate version:
Hibernate 3.05
Full stack trace of any exception that occurs:
Name and version of the database you are using:
Oracle 9i
Bonjour,
Je voudrais faire une jointure sur 2 objets qui n'ont pas de lien technique en Java et dans la table mais qui ont un lien metier.
Voici ma requete HQL:
Code:
"select count(*) from SightAccount as account left join Client as cl on account.coccRadi = cl.code where account.coccPcen in ( 1103, 1112, 5293 ) and cl.type in ( 5, 10, 11 ) "
Voici le l'exception que j'obtient:
Code:
org.hibernate.hql.ast.QuerySyntaxError: unexpected token: on near line 1, column 163 [select count(*) from mypackage.SightAccount as account left join Client as cl on account.coccRadi = cl.code where account.coccPcen in ( 1103, 1112, 5293 ) and cl.type in ( 5, 10, 11 ) ]
En regardant dans la doc j'ai pas trouvé la manière d'ecrire une requete avec left join, donc j'ai fait comme en SQL. Comment faire autrement?