mirror of
https://github.com/vrana/adminer.git
synced 2025-08-12 01:24:17 +02:00
NULL in SHOW COLUMNS can be empty
git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@71 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
@@ -41,7 +41,7 @@ function fields($table) {
|
||||
"length" => $match[2],
|
||||
"unsigned" => ltrim($match[3] . $match[4]),
|
||||
"default" => $row["Default"],
|
||||
"null" => ($row["Null"] != "NO"),
|
||||
"null" => ($row["Null"] == "YES"),
|
||||
"extra" => $row["Extra"],
|
||||
"collation" => $row["Collation"],
|
||||
"privileges" => explode(",", $row["Privileges"]),
|
||||
|
@@ -7,7 +7,7 @@ if (!$result) {
|
||||
} else {
|
||||
echo "<table border='1' cellspacing='0' cellpadding='2'>\n";
|
||||
while ($row = mysql_fetch_assoc($result)) {
|
||||
echo "<tr><th>" . htmlspecialchars($row["Field"]) . "</th><td>$row[Type]" . ($row["Null"] == "NO" ? "" : " <i>NULL</i>") . "</td></tr>\n";
|
||||
echo "<tr><th>" . htmlspecialchars($row["Field"]) . "</th><td>$row[Type]" . ($row["Null"] == "YES" ? " <i>NULL</i>" : "") . "</td></tr>\n";
|
||||
}
|
||||
echo "</table>\n";
|
||||
mysql_free_result($result);
|
||||
|
Reference in New Issue
Block a user