This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Object Relational Mapping and the fly likes Map-valued collections in HQL queries Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Map-valued collections in HQL queries" Watch "Map-valued collections in HQL queries" New topic

Map-valued collections in HQL queries

Alex Gr�nholm

Joined: May 15, 2008
Posts: 1

The above HQL query does not work, because Hibernate fails to connect the "cat" alias in the GROUP BY clause to the one being selected.
According to the Hibernate manual, it should be possible to give a function result an alias. However, Hibernate does not translate it to its proper value in the native SQL query.
What am I doing wrong?

The PurchaseInvoice class has:
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
subject: Map-valued collections in HQL queries
jQuery in Action, 3rd edition