From e8a5c18308d1bdbf35f1625c337eb6c440c8efc9 Mon Sep 17 00:00:00 2001 From: Sheikah45 Date: Sun, 17 Nov 2024 20:44:21 -0500 Subject: [PATCH] Fix for ReportQuery not fetching relationships with BatchFetch.IN --- .../src/org/eclipse/persistence/queries/ReportQuery.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/queries/ReportQuery.java b/foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/queries/ReportQuery.java index 7bd6d9c6a1f..9c2f9e281c8 100644 --- a/foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/queries/ReportQuery.java +++ b/foundation/org.eclipse.persistence.core/src/org/eclipse/persistence/queries/ReportQuery.java @@ -891,7 +891,12 @@ public Object executeDatabaseQuery() throws DatabaseException { return getDescriptor().getInterfacePolicy().selectAllObjectsUsingMultipleTableSubclassRead(this); } - return buildObjects(getQueryMechanism().selectAllReportQueryRows()); + List rows = getQueryMechanism().selectAllReportQueryRows(); + if ((this.batchFetchPolicy != null) && this.batchFetchPolicy.isIN()) { + this.batchFetchPolicy.setDataResults(rows); + } + + return buildObjects((Vector) rows); } /**