Joined: Tue Nov 27, 2007 7:53 am Posts: 5
|
Hi,
I have the following query
from DMSViewRowObject dmView where dmView.rowType=310 and dmView.index2=3 and dmView.index1 = (select dv.index1 from DMSViewRowObject dv where dv.data2= :publicID)
here my inner sub query returns multiple results.Hence using it this way would throw a sql exception.
but if i try doing like this i.e using limit 1
from DMSViewRowObject dmView where dmView.rowType=310 and dmView.index2=3 and dmView.index1 = (select dv.index1 from DMSViewRowObject dv where dv.data2= :publicID limit 1)
I get hibernate query exception.
I know a way using sql query but is there any other way out.
looking forward to your help
|
|