[wp-trac] [WordPress Trac] #24837: querying optimization for category AND searching
WordPress Trac
noreply at wordpress.org
Tue Aug 13 15:05:07 UTC 2013
#24837: querying optimization for category AND searching
-------------------------------------+------------------------------
Reporter: robertv123 | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Taxonomy | Version: 3.6
Severity: normal | Resolution:
Keywords: has-patch needs-testing |
-------------------------------------+------------------------------
Comment (by wonderboymusic):
When ordering by `post_date` - probably the most effective optimization is
forcing an index: `FROM wp_posts USE INDEX (type_status_date)`. This will
force the join type to be `range` instead of `index`. On a query with
`GROUP BY` and `ORDER BY`, the index forcing, for me, has made queries
faster un-cached than the cached queries without it.
Subqueries are sometimes rewritten internally by MySQL to perform worse
than JOINs.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/24837#comment:8>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list