Closed (outdated)
Project:
Drupal core
Version:
6.x-dev
Component:
comment.module
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
23 May 2010 at 13:18 UTC
Updated:
2 Mar 2016 at 22:18 UTC
Jump to comment: Most recent
Comments
Comment #1
damien tournoud commentedc.name AS registered_nameandu.name AS registered_nameare definitely not the same. That's why it is needed to join the users table. Not sure how that registered name is used down the road and if we can avoid it.Comment #2
damien tournoud commentedCrap. This is *again* a case where the MySQL query planner gets dumb:
Versus:
When the query is symmetric (all INNER JOINs), the query planner can order the tables the way it wants to. For some reason, it thinks that it will be easier to start from the {node} table, and get stuck with no index to do the sort on {comment}.timestamp. As soon as we make the query non-symmetric (by transforming the INNER JOIN to a LEFT JOIN), MySQL can satisfy the query from indexes alone.
Comment #4
sun.core commented