From 99f2b16da16492a1663296f13ec260d70ca5fc0e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michal=20=C4=8Ciha=C5=99?= Date: Tue, 3 Oct 2017 14:08:04 +0200 Subject: [PATCH] Lower default value for $cfg['MaxExactCount'] MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Counting of big InnoDB tables is slow, so try to avoid that as much as possible. Fixes #13711 Signed-off-by: Michal Čihař --- ChangeLog | 1 + doc/config.rst | 10 +++++++++- libraries/config.default.php | 2 +- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index e0869a4c2d..71a8790256 100644 --- a/ChangeLog +++ b/ChangeLog @@ -37,6 +37,7 @@ phpMyAdmin - ChangeLog - issue Consolidate functions into class files - issue #13560 Add support for changing collation for all tables and columns in database - issue #13303 Add support for creating fulltext index from table structure +- issue #13711 Lower default value for $cfg['MaxExactCount'] 4.7.5 (not yet released) - issue #13615 Avoid problems with browsing unknown query types diff --git a/doc/config.rst b/doc/config.rst index 4543c27ad1..91365b1c41 100644 --- a/doc/config.rst +++ b/doc/config.rst @@ -3107,7 +3107,7 @@ Various display setting .. config:option:: $cfg['MaxExactCount'] :type: integer - :default: 500000 + :default: 50000 For InnoDB tables, determines for how large tables phpMyAdmin should get the exact row count using ``SELECT COUNT``. If the approximate row @@ -3115,6 +3115,14 @@ Various display setting ``SELECT COUNT`` will be used, otherwise the approximate count will be used. + .. versionchanged:: 4.8.0 + + The default value was lowered to 50000 for performance reasons. + + .. versionchanged:: 4.2.6 + + The default value was changed to 500000. + .. seealso:: :ref:`faq3_11` .. config:option:: $cfg['MaxExactCountViews'] diff --git a/libraries/config.default.php b/libraries/config.default.php index 3c3036030f..5e8893804c 100644 --- a/libraries/config.default.php +++ b/libraries/config.default.php @@ -2761,7 +2761,7 @@ $cfg['BrowseMIME'] = true; * * @global integer $cfg['MaxExactCount'] */ -$cfg['MaxExactCount'] = 500000; +$cfg['MaxExactCount'] = 50000; /** * Zero means that no row count is done for views; see the doc