New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DDC-2622: Paginator with ORDER BY not working in MSSQL #3355
Comments
Comment created by flip101: I didn't get the Paginator working yet, but as i understand this is the first of 3 (maybe 2) queries, as described here: http://docs.doctrine-project.org/en/latest/tutorials/pagination.html It seems that in this first query it's not necessary to SELECT all these columns, so there is an opportunity here for a performance boost when not selecting them. (They still have to be selected in the final query to get the results). |
Comment created by @Ocramius: Just a note: the DQL query you're doing here is very dangerous hydration-wise. Don't ever filter on fetch-joined results. |
Comment created by @Ocramius: Provided patches at #789 and doctrine/dbal#371 |
Comment created by flip101: I don't understand your comment about filtering on fetch-join results being dangerous for hydration, could you please elaborate? |
Comment created by @Ocramius: [~flip101] it's unrelated to this change. I'd just explain that on IRC to avoid cluttering the issue here. |
Comment created by @doctrinebot: A related Github Pull-Request [GH-371] was closed: |
Comment created by flip101: Can be closed in favor of http://www.doctrine-project.org/jira/browse/[DDC-2687](http://www.doctrine-project.org/jira/browse/DDC-2687) |
Issue was closed with resolution "Duplicate" |
Comment created by @doctrinebot: |
Jira issue originally created by user flip101:
PHP code to test (A symfony 2.3 controller):
Schema:
One User to Many Reports
SQL + ERROR:
FIX:
Change
ORDER BY r0_.aangemaakt DESC
to
ORDER BY aangemaakt3 DESC
The text was updated successfully, but these errors were encountered: