Skip to content

Commit

Permalink
HHH-19207 - propose solution
Browse files Browse the repository at this point in the history
  • Loading branch information
Tamas Baranyi committed Feb 26, 2025
1 parent 09de492 commit b736610
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8323,6 +8323,15 @@ else if ( getLoadQueryInfluencers().hasEnabledFetchProfiles() ) {
}
else {
tableGroup = compatibleTableGroup;

if ( joinProducer instanceof PluralAttributeMapping attributeMapping ) {
if ( attributeMapping.getOrderByFragment() != null ) {
applyOrdering( tableGroup, attributeMapping.getOrderByFragment() );
}
if ( attributeMapping.getManyToManyOrderByFragment() != null ) {
applyOrdering( tableGroup, attributeMapping.getManyToManyOrderByFragment() );
}
}
}

// and return the joined group
Expand Down

0 comments on commit b736610

Please sign in to comment.