mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
Ignore orderBy in UOW eagerLoadCollections() method #7345
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @lewbor on GitHub (Mar 19, 2024).
Bug Report
Summary
When using a collection eager loading (UnitOfWork::eagerLoadCollections method), #[OrderBy] attribute on collection is ignoring now. In line
$found = $this->getEntityPersister($targetEntity)->loadAll([$mappedBy => $entities])it must be
$found = $this->getEntityPersister($targetEntity)->loadAll([$mappedBy => $entities], $mapping['orderBy']);@tomasz-ryba commented on GitHub (Mar 20, 2024):
It's an older problem already discussed here #11163 and seems to be related to changes introduced with #8391
@beberlei commented on GitHub (Apr 27, 2024):
Fixed by https://github.com/doctrine/orm/pull/11422