[wp-trac] [WordPress Trac] #10469: use of SQL_CALC_FOUND_ROWS needs to be eliminated
WordPress Trac
wp-trac at lists.automattic.com
Thu Jul 23 06:24:17 UTC 2009
#10469: use of SQL_CALC_FOUND_ROWS needs to be eliminated
--------------------------+-------------------------------------------------
Reporter: _ck_ | Owner: ryan
Type: defect (bug) | Status: new
Priority: normal | Milestone: Unassigned
Component: Query | Version:
Severity: normal | Keywords:
--------------------------+-------------------------------------------------
It's long overdue to rewrite a small part of
[https://core.trac.wordpress.org/browser/trunk/wp-includes/query.php
query.php], eliminating the use of SQL_CALC_FOUND_ROWS and switching to
COUNT(). Doing so will result in significant performance gains on active
sites.
SQL_CALC_FOUND_ROWS has serious performance degradation issues and it's
effects was even experienced on wordpress.org over two years ago before it
was removed from bbPress.
More here with links to documentation and benchmarks:
http://ckon.wordpress.com/2009/07/22/wordpress-still-uses-the-nasty-
sql_calc_found_rows/
My first rough attempt at a workaround that might be feasible:
http://pastebin.com/f45e1f9f6
--
Ticket URL: <http://core.trac.wordpress.org/ticket/10469>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list