[Hibernate-JIRA] Created: (HHH-6803) Still name clashes with aliases in SELECT statements
by Martin Dietze (JIRA)
Still name clashes with aliases in SELECT statements
----------------------------------------------------
Key: HHH-6803
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6803
Project: Hibernate Core
Issue Type: Bug
Components: core
Environment: Hibernate version 2.1.6, 2.1.7, 2.1.8, PostgresQL
Reporter: Martin Dietze
Attachments: Alias.diff
If in a table many column names exist with similar prefixes of a given length ending at numbers at the place of truncation, alias clashes in SELECT statements can occur leading to beans being incorrectly filled. This is a result of directly appending an auto-incremented number to the truncated name, e.g.:
abcdefghij0_.ABCD_VB1_VK_XY as ABCD_VB14_
abcdefghij0_.ABCD_VB2_ABCD_HIJKL as ABCD_VB14_
This leads to the value of field "ABCD_VB1_VK_XY" being assigned to the field "ABCD_VB2_ABCD_HIJKL", too!
This is a bug of the old Hibernate 2.1 versions. However since we (as probably other people, too) are using that version in an environment in which upgrading to Hibernate3 is not an option, and as this bug has potentially devastating effects, I would like to ask for a bugfix release. I have appended what I believe fixes the bug.
Thank you for your consideration!
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 1 month