MySQL: Don't quote default value of text fields (bug #779)
This commit is contained in:
parent
6e5315349b
commit
19f23fe9ee
|
@ -547,7 +547,7 @@ if (!defined("DRIVER")) {
|
|||
"type" => $match[1],
|
||||
"length" => $match[2],
|
||||
"unsigned" => ltrim($match[3] . $match[4]),
|
||||
"default" => ($row["Default"] != "" || preg_match("~char|set~", $match[1]) ? $row["Default"] : null),
|
||||
"default" => ($row["Default"] != "" || preg_match("~char|set~", $match[1]) ? (preg_match('~text~', $match[1]) ? stripslashes(preg_replace("~^'(.*)'\$~", '\1', $row["Default"])) : $row["Default"]) : null),
|
||||
"null" => ($row["Null"] == "YES"),
|
||||
"auto_increment" => ($row["Extra"] == "auto_increment"),
|
||||
"on_update" => (preg_match('~^on update (.+)~i', $row["Extra"], $match) ? $match[1] : ""), //! available since MySQL 5.1.23
|
||||
|
|
|
@ -4,6 +4,7 @@ Elasticsearch, ClickHouse: Do not print response if HTTP code is not 200
|
|||
Don't syntax highlight during IME composition (bug #747)
|
||||
MySQL: Do not export names in quotes with sql_mode='ANSI_QUOTES' (bug #749)
|
||||
MySQL: Avoid error in PHP 8 when connecting to socket (PR #409)
|
||||
MySQL: Don't quote default value of text fields (bug #779)
|
||||
PostgreSQL: Export all FKs after all CREATE TABLE (PR #351)
|
||||
PostgreSQL: Fix dollar-quoted syntax highlighting (bug #738)
|
||||
PostgreSQL: Do not show view definition from other schema (PR #392)
|
||||
|
|
Loading…
Reference in a new issue