So I sent an email to this list yesterday about an issue I encountered where I get malformed SQL when I make an HQL createQuery() call containing an "order by" clause which refers to a composite ID. I haven't gotten any responses to that email, but I've dived into the Hibernate source and am trying to fix it myself.

I'm trying to understand how Hibernate takes an HQL query, relates it to a mapping (in this case a composite ID), expands that mapping to get its contents (namely the different keys involved in the composite ID mapping) and translates that mapping into SQL. I've been looking at the ANTLR grammars involved and I see how the SQL queries are constructed, but I don't understand how the parser, upon seeing an order by clause that involves a composite key gets interpreted by the query engine and expanded into a SQL query. Can anyone shed some light on this, or give me a starting point? This is my first time looking at the Hibernate source; I'm kind of trying to find my feet. Any help would be greatly appreciated.

Thank you!
Bjorn Townsend



-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
hibernate-devel mailing list
hibernate-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hibernate-devel

Reply via email to