(no subject) [message #687508] |
Fri, 17 June 2011 05:01 |
Martin Taal Messages: 5468 Registered: July 2009 |
Senior Member |
|
|
I have not tried it but see this part of the HQL chapter in the Hibernate docs:
HQL functions that take collection-valued path expressions: size(), minelement(), maxelement(), minindex(), maxindex(), along with the special elements() and indices functions that can be quantified using some, all, exists, any, in.
you can try maxelement I guess in the whereclause:
select count(asset.ID) from Asset as asset, MobileProvider as mp where mp = maxelement(asset.StateInfo) and mp.Name='Vodafone'
Can you let me know if this works (cause then I know it to)?
gr. Martin
|
|
|
Powered by
FUDForum. Page generated in 0.02640 seconds