]> git.joonet.de Git - adminer.git/commitdiff
Fix EXPLAIN in MySQL < 5.1, bug since Adminer 3.6.4 (thanks to Coudy)
authorJakub Vrana <jakub@vrana.cz>
Sat, 11 May 2013 15:02:28 +0000 (08:02 -0700)
committerJakub Vrana <jakub@vrana.cz>
Sat, 11 May 2013 15:02:28 +0000 (08:02 -0700)
adminer/drivers/mysql.inc.php
changes.txt

index d7427172790b54933baa9ea87c71c0470458e21f..b99e87554644951408276fcbd3aa5b989650aaf5 100644 (file)
@@ -851,7 +851,7 @@ if (!defined("DRIVER")) {
        * @return Min_Result
        */
        function explain($connection, $query) {
-               return $connection->query("EXPLAIN " . ($connection->server_info ? "PARTITIONS " : "") . $query);
+               return $connection->query("EXPLAIN " . ($connection->server_info >= 5.1 ? "PARTITIONS " : "") . $query);
        }
        
        /** Get approximate number of rows
index ef0479d276138ee16395678de46ce6b255bafcfb..676d01d19089a63fb1ad5fb1b8ec1f9776e8fe99 100644 (file)
@@ -15,6 +15,7 @@ MySQL: Display bit type as binary number
 MySQL: Improve export of binary data types
 MySQL: Fix handling of POINT data type (bug #3582578)
 MySQL: Don't export binary and geometry columns twice in select
+MySQL: Fix EXPLAIN in MySQL < 5.1, bug since Adminer 3.6.4
 SQLite: Export views
 
 Adminer 3.6.4 (released 2013-04-26):