diff --git a/adminer/sql.inc.php b/adminer/sql.inc.php index 7c90d582..81be8728 100644 --- a/adminer/sql.inc.php +++ b/adminer/sql.inc.php @@ -109,11 +109,11 @@ if (!$error && $_POST) { } select($result, $connection2); echo "
" . ($result->num_rows ? lang('%d row(s)', $result->num_rows) : "") . $time; - if ($connection2 && preg_match("~^($space|\\()*SELECT\\b~isU", $q)) { + if ($connection2 && preg_match("~^($space|\\()*SELECT\\b~isU", $q) && ($explain = explain($connection2, $q))) { $id = "explain-$commands"; echo ", EXPLAIN\n"; echo "