[wp-trac] [WordPress Trac] #32770: sql with unnecessary * in comment.php

WordPress Trac noreply at wordpress.org
Tue Jun 23 20:51:17 UTC 2015


#32770: sql with unnecessary * in comment.php
---------------------------+--------------------------
 Reporter:  mesaquesoares  |       Owner:
     Type:  enhancement    |      Status:  closed
 Priority:  normal         |   Milestone:
Component:  General        |     Version:  4.2.2
 Severity:  normal         |  Resolution:  invalid
 Keywords:                 |     Focuses:  performance
---------------------------+--------------------------
Changes (by boonebgorges):

 * status:  new => closed
 * resolution:   => invalid
 * milestone:  Awaiting Review =>


Comment:

 Hi mesaquesoares - `COUNT(*)` should be at least as fast as
 `COUNT(comment_ID)`, and possibly faster, as miqrogroove points out. See
 eg http://stackoverflow.com/a/4216154 and
 http://stackoverflow.com/questions/1697137/countid-vs-count-in-mysql. If
 you have an `EXPLAIN` that shows otherwise, please feel free to post it.

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


More information about the wp-trac mailing list