[hibernate-issues] [Hibernate-JIRA] Created: (HHH-3389) HQL generates wrong sql when using subquery on the same table