[wp-trac] [WordPress Trac] #31071: post_mime_type related queries still slow on larger sites

WordPress Trac noreply at wordpress.org
Tue Jan 20 13:07:17 UTC 2015


#31071: post_mime_type related queries still slow on larger sites
--------------------------+------------------------------
 Reporter:  archon810     |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Media         |     Version:  4.1
 Severity:  normal        |  Resolution:
 Keywords:                |     Focuses:  performance
--------------------------+------------------------------

Comment (by archon810):

 OK, without resorting to giving MySQL hints in the form of `USE INDEX` or
 `FORCE INDEX`, adding an index on (`post_type`, `post_date`) finally made
 it automatically use it to resolve the query in #comment:1 using an index.
 In fact, there's an improvement - "using filesort" which was there before
 in both cases is now gone: "Using where; Using index; Using temporary".

 The query runs fast now.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/31071#comment:2>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list