HHH-18259 Fix check for generated properties for root table only

This commit is contained in:
Marco Belladelli 2024-06-12 09:21:27 +02:00 committed by Christian Beikov
parent 24dd943c7b
commit b3d01730ce
1 changed files with 1 additions and 1 deletions

View File

@ -4744,7 +4744,7 @@ public abstract class AbstractEntityPersister
for ( AttributeMapping generatedAttribute : generatedAttributes ) {
// todo (7.0) : support non selectable mappings? Component, ToOneAttributeMapping, ...
if ( generatedAttribute.asBasicValuedModelPart() != null
&& generatedAttribute.getContainingTableExpression().equals( getSubclassTableName( 0 ) ) ) {
&& generatedAttribute.getContainingTableExpression().equals( getRootTableName() ) ) {
generatedBasicAttributes.add( generatedAttribute );
}
}