HHH-17105 Consider dialect qualifier support in collection cleanup

This commit is contained in:
Marco Belladelli 2023-09-06 17:47:35 +02:00 committed by Christian Beikov
parent 7048a72c61
commit 93f423f3f9
1 changed files with 2 additions and 1 deletions

View File

@ -10,6 +10,7 @@ import java.util.List;
import java.util.Map;
import org.hibernate.action.internal.BulkOperationCleanupAction;
import org.hibernate.dialect.DmlTargetColumnQualifierSupport;
import org.hibernate.engine.jdbc.spi.JdbcServices;
import org.hibernate.engine.spi.SessionFactoryImplementor;
import org.hibernate.engine.spi.SharedSessionContractImplementor;
@ -144,7 +145,7 @@ public class SimpleDeleteQueryPlan implements NonSelectQueryPlan {
attributeMapping.applyBaseRestrictions(
p -> additionalPredicate.set( Predicate.combinePredicates( additionalPredicate.get(), p ) ),
collectionTableGroup,
false,
factory.getJdbcServices().getDialect().getDmlTargetColumnQualifierSupport() == DmlTargetColumnQualifierSupport.TABLE_ALIAS,
executionContext.getSession().getLoadQueryInfluencers().getEnabledFilters(),
null,
null