From: Alexander Ebert Date: Thu, 1 Mar 2012 14:40:15 +0000 (+0100) Subject: Fixed handling of DEFAULT values X-Git-Tag: 2.0.0_Beta_1~1281^2~3 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=74d5501c78852b5f38e684613e776ab5d2da5726;p=GitHub%2FWoltLab%2FWCF.git Fixed handling of DEFAULT values --- diff --git a/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php b/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php index 8412c657e4..3e798dfe52 100644 --- a/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php +++ b/wcfsetup/install/files/lib/system/database/editor/MySQLDatabaseEditor.class.php @@ -198,7 +198,7 @@ class MySQLDatabaseEditor extends DatabaseEditor { // not null / null if (!empty($columnData['notNull'])) $definition .= " NOT NULL"; // default - if (isset($columnData['default']) && $columnData['default'] !== '') $definition .= " DEFAULT ".$columnData['default']; + if (isset($columnData['default']) && $columnData['default'] !== '') $definition .= " DEFAULT '".$columnData['default']."'"; // auto_increment if (!empty($columnData['autoIncrement'])) $definition .= " AUTO_INCREMENT"; // key