You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using the query builder, and doing a leftJoinAndSelect followed by a orderBy, the order is not taken into account (seems like it's then ordered by ids instead)
Interesting, another issue there is that .leftJoinAndSelect('b', 'b') is not populating the b property - that is because of the same table and alias name apparently, as .leftJoinAndSelect('b', 'b0') fixes that particular problem.
Previously fetch-joining failed when there was a conflict in aliased property name
and parent entity property name and the alias is same as the parent property name
(e.g. property `Book.author` and alias `author`).
Related #1171
Describe the bug
When using the query builder, and doing a
leftJoinAndSelect
followed by aorderBy
, the order is not taken into account (seems like it's then ordered by ids instead)Stack trace
To Reproduce
Steps to reproduce the behavior:
Here's a reproduction repo
Expected behavior
When doing an
orderby
, the order of the resulting list should be the same, whether there is a join or not.Additional context
The current workaround for this issue is to use the sort method, but it can be costly for long lists
Versions
The text was updated successfully, but these errors were encountered: