HHH-10247 - Fix Hibernate ignores foreign-key attribute name in hbm <many-to-many>

This commit is contained in:
Andrea Boriero 2015-11-12 20:14:02 +00:00
parent 8c0c98fa07
commit c0528b7079
1 changed files with 1 additions and 0 deletions

View File

@ -3570,6 +3570,7 @@ public class ModelBinder {
: FetchMode.JOIN
);
elementBinding.setForeignKeyName( elementSource.getExplicitForeignKeyName() );
elementBinding.setReferencedEntityName( elementSource.getReferencedEntityName() );
if ( StringHelper.isNotEmpty( elementSource.getReferencedEntityAttributeName() ) ) {