From 7ce79142c0228ff987797e46dc43ce6ed3f6734b Mon Sep 17 00:00:00 2001 From: jakubvrana Date: Sat, 11 Aug 2007 06:43:01 +0000 Subject: [PATCH] sql_mode NO_FIELD_OPTIONS should be disabled git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@333 7c3ca157-0c34-0410-bff1-cbf682f78f5c --- edit.inc.php | 1 + 1 file changed, 1 insertion(+) diff --git a/edit.inc.php b/edit.inc.php index da5df0eb..8714a355 100644 --- a/edit.inc.php +++ b/edit.inc.php @@ -85,6 +85,7 @@ if ($fields) { if (isset($_GET["default"]) && $field["type"] == "timestamp") { $id = htmlspecialchars("on_update-$name"); if (!isset($create) && !$_POST) { + //! disable sql_mode NO_FIELD_OPTIONS $create = $mysql->result($mysql->query("SHOW CREATE TABLE " . idf_escape($_GET["edit"])), 1); } $checked = ($_POST ? $_POST["on_update"][bracket_escape($name)] : preg_match("~\n\\s*" . preg_quote(idf_escape($name), '~') . " timestamp.* on update CURRENT_TIMESTAMP~i", $create));