mirror of
https://github.com/vrana/adminer.git
synced 2025-08-07 23:27:17 +02:00
SQLite: Fix expressions in default values (bug #860)
This commit is contained in:
@@ -319,7 +319,7 @@ if (isset($_GET["sqlite"]) || isset($_GET["sqlite2"])) {
|
||||
"field" => $name,
|
||||
"type" => (preg_match('~int~i', $type) ? "integer" : (preg_match('~char|clob|text~i', $type) ? "text" : (preg_match('~blob~i', $type) ? "blob" : (preg_match('~real|floa|doub~i', $type) ? "real" : "numeric")))),
|
||||
"full_type" => $type,
|
||||
"default" => (preg_match("~'(.*)'~", $default, $match) ? str_replace("''", "'", $match[1]) : ($default == "NULL" ? null : $default)),
|
||||
"default" => (preg_match("~^'(.*)'$~", $default, $match) ? str_replace("''", "'", $match[1]) : ($default == "NULL" ? null : $default)),
|
||||
"null" => !$row["notnull"],
|
||||
"privileges" => array("select" => 1, "insert" => 1, "update" => 1),
|
||||
"primary" => $row["pk"],
|
||||
|
Reference in New Issue
Block a user