mirror of
https://github.com/doctrine/orm.git
synced 2026-03-24 06:52:09 +01:00
DDC-2622: Paginator with ORDER BY not working in MSSQL #3290
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 @doctrinebot on GitHub (Aug 20, 2013).
Originally assigned to: @Ocramius on GitHub.
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 DESCto
ORDER BY aangemaakt3 DESC@doctrinebot commented on GitHub (Aug 20, 2013):
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).
@doctrinebot commented on GitHub (Sep 15, 2013):
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.
@doctrinebot commented on GitHub (Sep 15, 2013):
Comment created by @ocramius:
Provided patches at https://github.com/doctrine/doctrine2/pull/789 and https://github.com/doctrine/dbal/pull/371
@doctrinebot commented on GitHub (Sep 16, 2013):
Comment created by flip101:
I don't understand your comment about filtering on fetch-join results being dangerous for hydration, could you please elaborate?
@doctrinebot commented on GitHub (Sep 16, 2013):
Comment created by @ocramius:
[~flip101] it's unrelated to this change. I'd just explain that on IRC to avoid cluttering the issue here.
@doctrinebot commented on GitHub (Sep 16, 2013):
Comment created by @doctrinebot:
A related Github Pull-Request [GH-371] was closed:
https://github.com/doctrine/dbal/pull/371
@doctrinebot commented on GitHub (Jan 12, 2014):
Comment created by flip101:
Can be closed in favor of http://www.doctrine-project.org/jira/browse/DDC-2687
@doctrinebot commented on GitHub (Jan 12, 2014):
Comment created by @ocramius:
Handled in DDC-2687
@doctrinebot commented on GitHub (Jan 12, 2014):
Issue was closed with resolution "Duplicate"
@doctrinebot commented on GitHub (Apr 4, 2014):
Comment created by @doctrinebot:
A related Github Pull-Request [GH-789] was closed:
https://github.com/doctrine/doctrine2/pull/789