Actually, something is still wrong.
Hibernate loaded the hbm files, but the generated SQL is different now.
Code:
12:22:18,233 DEBUG [SQL] select operazione0_.ID as ID9_, operazione0_.AZIENDA as AZIENDA9_, operazione0_.CODICE as CODICE9_, ope
razione0_.DESCRIZIONE as DESCRIZI4_9_, operazione0_.DESC_BREVE as DESC5_9_, operazione0_.TIPO_CODICE as TIPO6_9_, operazione0_.A
ZIONE1 as AZIONE7_9_, operazione0_.AZIONE2 as AZIONE8_9_, operazione0_.AZIONE3 as AZIONE9_9_, operazione0_.AZIONE4 as AZIONE10_9
_, operazione0_.OPER_GUIDATA as OPER11_9_, operazione0_.UT_CREAZIONE as UT12_9_, operazione0_.UT_MODIFICA as UT13_9_, operazione
0_.TS_CREAZIONE as TS14_9_, operazione0_.TS_MODIFICA as TS15_9_, operazione0_.OPERAZIONE.AZIONE1 as OPERAZIONE16_9_, operazione0
_.OPERAZIONE.AZIONE2 as OPERAZIONE17_9_, operazione0_.OPERAZIONE.AZIONE3 as OPERAZIONE18_9_, operazione0_.OPERAZIONE.AZIONE4 as
OPERAZIONE19_9_ from OPERAZIONE operazione0_ order by operazione0_.CODICE
Four clauses were added, like this :
Code:
operazione0_.OPERAZIONE.AZIONE1 as OPERAZIONE16_9_
In my environment the query fails becuase operazione... is too long for DB2/400, but I think it's wrong anyway.
Obviously the .OPERAZIONE. in the middle is not needed, but I understand that I specified in the hbm to do so. I didn't think it would re-query those four columns.
In version 3.1 I didn't have this issue.
I still believe that it's an error in my mapping file (in the first post), just don't find it.
Giulio