From 01a27e8d26917da45ca1891140b968d37e8f7e67 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Fri, 1 Apr 2005 20:59:46 +0000 Subject: [PATCH] bug #1163595, problem 6 --- libraries/common.lib.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libraries/common.lib.php b/libraries/common.lib.php index 45cab2201..c22c9d174 100644 --- a/libraries/common.lib.php +++ b/libraries/common.lib.php @@ -2541,7 +2541,8 @@ if (typeof(document.getElementById) != 'undefined' if ($default_current_timestamp && strtoupper($full_field_type) == 'TIMESTAMP') { $query .= ' DEFAULT CURRENT_TIMESTAMP'; - } elseif (!empty($default)) { + // 0 is empty in PHP + } elseif (!empty($default) || $default == '0') { if (strtoupper($default) == 'NULL') { $query .= ' DEFAULT NULL'; } else {