Issue Type: Bug Bug
Affects Versions: 4.1.1
Assignee: Unassigned
Attachments: test_case.zip
Components: annotations
Created: 04/Jul/12 12:11 PM
Description:

In a @Formula with complex query using aggregate function and condition on primary key like this:

@Formula("(select count(st._uid) from secondary_table st where st.user_account=uid_)")

if property starts width underscore (i.e. _uid) and both involved tables have same column Hibernate uses secondary_table __uid_ properties in equal condition.

(See attached test_case where last sysout column is wrong)

Environment: Windows 7, Java 1.6.0_15
Project: Hibernate ORM
Priority: Major Major
Reporter: Simone Maratea
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators.
For more information on JIRA, see: http://www.atlassian.com/software/jira