Open
Description
There is a bug in query selecting IDs that are passed for query selecting paged items.
1st query = selecting count;
2nd query = selecting IDs that are selected in 3rd query ( using LIMIT ... OFFSET... )
3rd query = selecting items that are displayed
How to get to bug:
Lets say I have this query:
Entity\Gallery = media__gallery
Entity\Media = media__media
Entity\GalleryHasMedia = media__gallery_media
So basically what Im doing is selecting 'm' (Media) for displaying in paginated results.
The 2nd query thus should select not u0_id but m1_.id so it can be used in 3rd query in WHERE statement.
What it does now is instead of filling WHERE with (m1.)_Media IDs its using (u0.)_UserGallery IDs...