Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fix tables list in Editor

  • Loading branch information...
commit 516416e72b1413cfa3dd88159aec67be2c22b7b4 1 parent c386554
@vrana authored
Showing with 2 additions and 2 deletions.
  1. +2 −2 adminer/drivers/mysql.inc.php
View
4 adminer/drivers/mysql.inc.php
@@ -373,14 +373,14 @@ function table_status($name = "", $fast = false) {
global $connection;
$return = array();
foreach (get_rows($fast && $connection->server_info >= 5
- ? "SELECT table_name AS Name, Engine, TABLE_COMMENT AS Comment FROM information_schema.TABLES WHERE table_schema = " . q(DB) . ($name != "" ? " AND table_name = " . q($name) : "")
+ ? "SELECT TABLE_NAME AS Name, Engine, TABLE_COMMENT AS Comment FROM information_schema.TABLES WHERE TABLE_SCHEMA = DATABASE()" . ($name != "" ? " AND TABLE_NAME = " . q($name) : "")
: "SHOW TABLE STATUS" . ($name != "" ? " LIKE " . q(addcslashes($name, "%_\\")) : "")
) as $row) {
if ($row["Engine"] == "InnoDB") {
// ignore internal comment, unnecessary since MySQL 5.1.21
$row["Comment"] = preg_replace('~(?:(.+); )?InnoDB free: .*~', '\\1', $row["Comment"]);
}
- if (!isset($row["Rows"])) {
+ if (!isset($row["Engine"])) {
$row["Comment"] = "";
}
if ($name != "") {
Please sign in to comment.
Something went wrong with that request. Please try again.