Ejb3JoinColumn.linkValueUsingDefaultColumnNaming messes up logical/physical column name
---------------------------------------------------------------------------------------
Key: ANN-839
URL:
http://opensource.atlassian.com/projects/hibernate/browse/ANN-839
Project: Hibernate Annotations
Issue Type: Bug
Components: binder
Affects Versions: 3.4.0.GA
Reporter: Marat Radchenko
Ejb3JoinColumn.java pretends columnName variable (line 270) is a physical column name (it
is proved on line 323).
However.
1. initMappingColumn is called with applyNamingStrategy=false
2. It in turn calls redefineColumnName (still applyNamingStrategy=false).
3. applyNamingStrategy=false -> if statement on line 186 is evaluated to false
4. line 198, original value of columnName is used as _physical_ column name.
So what we get is the same string used as both logical and physical name without any
consulting with NamingStrategy. This behavior completely breaks our setup (we want to
quote all physical column names).
Proposed solution:
1. Rename columnName to logicalColumnName so assumptions about its usage are more
explicit.
2. Call initMappingColumn with applyNamingStrategy=true
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira