Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Subquery in Hibernate 2.0

 
sudha swami
Ranch Hand
Posts: 186
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am using following subquery in Hibernate:It comes up with the error: missing right paranthesis

Table:
-----

Area
----
modifiedTS timestamp
id number
pkgId number
serialNumber varchar2

select serialNo.id from Area area where area.pkgId=3 and area.modifiedTS in(select max(a.modifiedTS) from Area a where a.pkgId=3 group by a.serialNumber)

Underlying database is Oracel 9.0. The above query executes in oracle but i couldnt figure out why it is not working in hiberate.

Any help is appreciated.

regards
sudha
 
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!