HHH-17205 Avoid select by unique key with no referenced property
This commit is contained in:
parent
dcf1f1aa95
commit
c021287296
|
@ -1725,6 +1725,9 @@ public class ToOneAttributeMapping
|
||||||
}
|
}
|
||||||
|
|
||||||
private boolean isSelectByUniqueKey(ForeignKeyDescriptor.Nature side) {
|
private boolean isSelectByUniqueKey(ForeignKeyDescriptor.Nature side) {
|
||||||
|
if ( referencedPropertyName == null ) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
if ( side == ForeignKeyDescriptor.Nature.KEY ) {
|
if ( side == ForeignKeyDescriptor.Nature.KEY ) {
|
||||||
// case 1.2
|
// case 1.2
|
||||||
return !foreignKeyDescriptor.getNavigableRole()
|
return !foreignKeyDescriptor.getNavigableRole()
|
||||||
|
|
Loading…
Reference in New Issue