[hibernate-issues] [Hibernate-JIRA] Created: (HBX-1151) let JDBCBinder check for excluded foreign key columns in many-to-many tables
Andreas Brieg (JIRA)
noreply at atlassian.com
Thu Nov 5 06:03:08 EST 2009
let JDBCBinder check for excluded foreign key columns in many-to-many tables
----------------------------------------------------------------------------
Key: HBX-1151
URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-1151
Project: Hibernate Tools
Issue Type: Patch
Affects Versions: 3.2.4.GA
Environment: hibernate-tools revision 17926
Reporter: Andreas Brieg
Priority: Minor
Attachments: jdbcbinder_check_foreignkey_excluded_for_many_to_many_table.patch
When processing a many-to-many table the JDBCBinder looks only for other foreign key columns in the many-to-many table in method bindOneToMany(PersistentClass, ForeignKey, Set, Mapping) but it doesn't ask the reverse engineering strategy if those foreign key columns are excluded.
The patch changes the bindOneToMany(PersistentClass, ForeignKey, Set, Mapping) method when processing a many-to-many table so that it asks the reverse engineering strategy if the foreign key is excluded. Only if it isn't excluded it is chosen for the mapping of the other side of the many-to-many table.
This lets you map tables many-to-many tables, which have a third optional foreign key. This may be needed in case the optional foreign key is only used by other modules, which access the database.
--
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.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list