Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version:
version 3.1
Mapping documents:
Code between sessionFactory.openSession() and session.close():
Full stack trace of any exception that occurs:
Name and version of the database you are using:
The generated SQL (show_sql=true):
Help me !!!
Can I translate this sql query in hql:
I try to mapping this property with a formula in hbm.xml but the result is not a same.
select
Ordine.crete
from
tavc8200 Ordine inner join
tavc8220 ClienteOrdine
on Ordine.CID = ClienteOrdine.FK_8200_CID
inner join
tavc8210 RigaOrdine
on Ordine.CID = RigaOrdine.FK_8200_CID
left outer join
tmkt0009 AnagTestataModulo
on Ordine.crete = AnagTestataModulo.crete and RigaOrdine.ctestata = AnagTestataModulo.ctestata
left outer join
tmkt0022 PubblEmittComm
on Ordine.dcomanno = PubblEmittComm.ncommissione_anno
and
Ordine.ncomprog=PubblEmittComm.ncommissione_progressivo
and
RigaOrdine.nprricom =PubblEmittComm.ncommiss_riga_progressivo
where
Ordine.crete in ('C5', 'R4', 'K1', 'SA') and -- Reti
ClienteOrdine.ccliente = '1540118'
I found much problem with left outer Join with an 'And'
Sorry for my orrible english ^_^
Debug level Hibernate log excerpt:
Problems with Session and transaction handling?
Read this:
http://hibernate.org/42.html