From 24b516253adadff9348827ebd5538fc2f4ffcf71 Mon Sep 17 00:00:00 2001 From: Andrea Boriero Date: Mon, 8 Jan 2024 17:19:02 +0100 Subject: [PATCH] HHH-17307 Hibernate 6 ListResultsConsumer.Results#addUnique really slow for ElementCollections --- .../loader/ast/internal/CollectionLoaderSubSelectFetch.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hibernate-core/src/main/java/org/hibernate/loader/ast/internal/CollectionLoaderSubSelectFetch.java b/hibernate-core/src/main/java/org/hibernate/loader/ast/internal/CollectionLoaderSubSelectFetch.java index 67118de200..967e94d9b4 100644 --- a/hibernate-core/src/main/java/org/hibernate/loader/ast/internal/CollectionLoaderSubSelectFetch.java +++ b/hibernate-core/src/main/java/org/hibernate/loader/ast/internal/CollectionLoaderSubSelectFetch.java @@ -138,7 +138,7 @@ public class CollectionLoaderSubSelectFetch implements CollectionLoader { this.subselect.getLoadingJdbcParameterBindings(), new ExecutionContextWithSubselectFetchHandler( session, subSelectFetchableKeysHandler ), RowTransformerStandardImpl.instance(), - ListResultsConsumer.UniqueSemantic.FILTER + ListResultsConsumer.UniqueSemantic.NONE ); if ( subSelectFetchedCollections != null && ! subSelectFetchedCollections.isEmpty() ) {