[b]Hibernate version:3.1[/b]
I'm also using Spring framework.
Hello all.
I need to build a HQL query that performs an outer join between two non associates entities.
I just want to reproduce the following sql query in HQL:
select table_a.id as col_0,
table_b.score_1-table_a.score_1 as col_1,
table_b.score_2-table_a.score_2 as col_2,
table_b.score_3-table_a.score_3 as col_3,
table_b.score_4-table_a.score_4 as col_4
from p_audit as table_a left join p_audit as table_b on (table_a.join_id=table_b.join_id and table_b.filter_id=6)
where table_a.filter_id=1058
order by 2
Table p_audit corresponds to the Pojo Audit...
Anybody know how could I perform this query? Is this possible in HQL?
Thanks in advance.
|