[
http://opensource.atlassian.com/projects/hibernate/browse/HBX-1131?page=c...
]
Eric Sirianni commented on HBX-1131:
------------------------------------
Actually, my suggestion of just blindly incrementing bogusFkName doesn't work when
there are keys consisting of multiple columns.
JDBCReader incorrectly generates bogus FK names
-----------------------------------------------
Key: HBX-1131
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HBX-1131
Project: Hibernate Tools
Issue Type: Bug
Affects Versions: 3.2.4.GA
Environment: Tools 3.2.4 GA
Reporter: Eric Sirianni
Please see my forum post@
https://forum.hibernate.org/viewtopic.php?f=6&t=996016&p=2416464#...
JDBC drivers are allowed to return NULL for the "FK_NAME" metadata field for
foreign keys.
In this case, hibernate tries to generate a bogus FK name. This FK name must be unique
for the Table otherwise an exception is thrown:
org.hibernate.cfg.JDBCBinderException: Foreign key name (0) mapped to different
tables!
Hibernate's algorithm for generating the bogus FK name appears to be wrong. It
should increment the bogus FK name for each FK it finds, irrelevant of the
"KEY_SEQ" value.
--
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