SQL_CALC_FOUND_ROWS
| User, date | Message |
|---|---|
|
Written by andyr
6 years ago Category: General 7 posts since Tue, 27 Mar 07 |
First of all, good to see the 'proper' mysqlfront making a come back I have an issue with the SQL_CALC_FOUND_ROWS usage. We have some tables with over 6 million rows. When browsing the data to filter, the initial load of the data takes a v. long time due to the SELECT SQL_CALC_FOUND_ROWS * FROM statistics LIMIT 0, 50 Would it be possible to use a count(*) when initially browsing to the table (before any filters applied) as this would be v. quick when using MyISAM tables? Or, would it be possible to turn off SQL_CALC_FOUND_ROWS somehow? Or use the Rows column from 'show tables status' to determine whether to use sql_calc_found_rows if smaller than a certain limit? |
|
Written by ansgar
6 years ago 3949 posts since Fri, 07 Apr 06 |
Good idea: Disable the SQL_CALC_FOUND_ROWS for the benefit of a COUNT(), as long as no filter was applied. Not sure if that gets into the 3.0 final. |
|
Written by ansgar
6 years ago 3949 posts since Fri, 07 Apr 06 |
andyr wrote: Would it be possible to use a count(*) when initially browsing to the table (before any filters applied) as this would be v. quick when using MyISAM tables? Done in revision 543. |
|
Written by andyr
6 years ago 7 posts since Tue, 27 Mar 07 |
Brilliant |
|
Please login to leave a reply, or register at first. |