[Phpmyadmin-git] [SCM] phpMyAdmin branch, master, updated. RELEASE_3_3_4RC1-5230-g1be2d53

Marc Delisle lem9 at users.sourceforge.net
Thu Jun 24 16:09:29 CEST 2010


The branch, master has been updated
       via  1be2d538dfae929582b9ff6b4a6bdc643609da9e (commit)
       via  4c0e653de0aa48c277a2612f70d0c17442bf779c (commit)
       via  8b1b49a6b2dfc4da4c8ac8f2f3feda62e5894ce6 (commit)
       via  318ebf8bb5a45c892cfc1c21c78a10188733d14d (commit)
       via  41b2a7802c17fa2bf6f59442ab5c75be00c9ec10 (commit)
       via  4f56db9d935d0018bbdaa30abcc1588a03e8bc30 (commit)
       via  12edc03e2f1953bdfdecc7eaaec760e6821b4286 (commit)
       via  d10de675cef47123af1e91d793430e8fd5eb5338 (commit)
       via  b95666b22d2cb0a1119341bfc64d28cd77f5be28 (commit)
      from  6bb0cef5360aa53ebef4df12dac3f80c4fd60273 (commit)


- Log -----------------------------------------------------------------
commit 1be2d538dfae929582b9ff6b4a6bdc643609da9e
Merge: 6bb0cef5360aa53ebef4df12dac3f80c4fd60273 4c0e653de0aa48c277a2612f70d0c17442bf779c
Author: Marc Delisle <marc at infomarc.info>
Date:   Thu Jun 24 10:09:19 2010 -0400

    fix merge conflicts

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog                        |    2 ++
 libraries/mysql_charsets.lib.php |   12 +++++++++++-
 2 files changed, 13 insertions(+), 1 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 460da38..4572a25 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -86,6 +86,8 @@ $Id$
 - [core] Update library PHPExcel to version 1.7.3c
 
 3.3.5.0 (not yet released)
+- patch #2932113 [information_schema] Slow export when having lots of
+  databases, thanks to St├ęphane Pontier - shadow_walker
 
 3.3.4.0 (not yet released)
 - bug #2996161 [import] properly escape import value
diff --git a/libraries/mysql_charsets.lib.php b/libraries/mysql_charsets.lib.php
index 40ce377..1782a3e 100644
--- a/libraries/mysql_charsets.lib.php
+++ b/libraries/mysql_charsets.lib.php
@@ -164,7 +164,17 @@ function PMA_getDbCollation($db) {
         return 'utf8_general_ci';
     }
 
-    return PMA_DBI_fetch_value('SELECT DEFAULT_COLLATION_NAME FROM information_schema.SCHEMATA WHERE SCHEMA_NAME = \'' . PMA_sqlAddSlashes($db) . '\' LIMIT 1;');
+    if (! $GLOBALS['cfg']['Server']['DisableIS']) {
+        // this is slow with thousands of databases
+        return PMA_DBI_fetch_value('SELECT DEFAULT_COLLATION_NAME FROM information_schema.SCHEMATA WHERE SCHEMA_NAME = \'' . PMA_sqlAddSlashes($db) . '\' LIMIT 1;');
+    } else {
+        PMA_DBI_select_db($db);
+        $return = PMA_DBI_fetch_value('SHOW VARIABLES LIKE \'collation_database\'', 0, 1);
+        if ($db !== $GLOBALS['db']) {
+            PMA_DBI_select_db($GLOBALS['db']);
+        }
+        return $return;
+    }
 }
 
 /**


hooks/post-receive
-- 
phpMyAdmin




More information about the Git mailing list