I am trying to do a left outer join between two tables. I keep getting the below exception when trying to run it. I did find this posting
http://forum.hibernate.org/viewtopic.php?p=2187152&sid=dd72de4c41b85bf79e93258e98b2bb49, but that is from 2004 and I would think that something has changed by now. Can somebody shed some light and let me know if this is still the case.
I am using Hibernate 3 and running an Oracle 9i database.
Exception:
Code:
org.hibernate.hql.ast.QuerySyntaxException: unexpected token: on near line 4, column 1 [select pi.code, pi.name, pi.address, pi.phone,
pi.loc, pi.currency, pp.general
from com.property.PropertyInfo pi left outer join PropertyProfile pp
on (pi.code = pp.code)
where pi.code = rpad(upper(:code),8)]
The original query looked like this:
Code:
select pi.code, pi.name, pi.address, pi.phone,
pi.loc, pi.currency, pp.general
from com.property.PropertyInfo pi, PropertyProfile pp
where pi.code = rpad(upper(:code),8)]
and pi.code = pp.code (+)