When loading related one-to-many entities, EF adds ORDER BY clauses to make sure all related entities for a given entity are grouped together. However, we can remove the last ORDER BY clause as it is unnecessary and causes more work (see #19571).
When loading related one-to-many entities, EF adds ORDER BY clauses to make sure all related entities for a given entity are grouped together.
However, we can remove the last ORDER BY clause as it is unnecessary and causes more work (see #19571).