0

I wrote the following HQL:

select currency, rate from Currency as currency left outer join ExchangeRate as rate where currency.code = rate.currencyCode

And when I execute it I get: No data type for node: org.hibernate.hql.ast.tree.IdentNode \r\n \\-[IDENT] IdentNode: 'rate' {originalText=rate}\r\n

I found some questions on stackoverflow such as What's wrong with this HQL? "No data type for node" but in my case rate is defined in my join. And suggestions are appreciated.

Community
  • 1
  • 1
  • Are you sure code is the foriegn key? Can you please send the table constraints and also the entity classes? – Pratik Shelar Sep 26 '13 at 09:37
  • Yes, code is the FK. And I don't have access to the code right now, but the fields are non null, one currency > many rates. And they are both present in my persistence.xml – John Deckers Sep 26 '13 at 10:41

0 Answers0