bug #1406378, default value and auto_increment
This commit is contained in:
@@ -5,6 +5,9 @@ phpMyAdmin - Changelog
|
|||||||
$Id$
|
$Id$
|
||||||
$Source$
|
$Source$
|
||||||
|
|
||||||
|
2006-02-15 Marc Delisle <lem9@users.sourceforge.net>
|
||||||
|
* bug #1406378, default value and auto_increment, thanks to Nuvo - nyvsld
|
||||||
|
|
||||||
2006-02-14 Marc Delisle <lem9@users.sourceforge.net>
|
2006-02-14 Marc Delisle <lem9@users.sourceforge.net>
|
||||||
* Documentation.html: XHTML error, thanks to Cédric Corazza
|
* Documentation.html: XHTML error, thanks to Cédric Corazza
|
||||||
* Documentation.html: remove experimental status for MySQL 4.1 support
|
* Documentation.html: remove experimental status for MySQL 4.1 support
|
||||||
|
@@ -2511,7 +2511,8 @@ window.parent.updateTableTitle('<?php echo $uni_tbl; ?>', '<?php echo PMA_jsForm
|
|||||||
if ($default_current_timestamp && strpos(' ' . strtoupper($type), 'TIMESTAMP') == 1) {
|
if ($default_current_timestamp && strpos(' ' . strtoupper($type), 'TIMESTAMP') == 1) {
|
||||||
$query .= ' DEFAULT CURRENT_TIMESTAMP';
|
$query .= ' DEFAULT CURRENT_TIMESTAMP';
|
||||||
// 0 is empty in PHP
|
// 0 is empty in PHP
|
||||||
} elseif (!empty($default) || $default == '0' || $default != $default_orig) {
|
// auto_increment field cannot have a default value
|
||||||
|
} elseif ($extra !== 'AUTO_INCREMENT' && (!empty($default) || $default == '0' || $default != $default_orig)) {
|
||||||
if (strtoupper($default) == 'NULL') {
|
if (strtoupper($default) == 'NULL') {
|
||||||
$query .= ' DEFAULT NULL';
|
$query .= ' DEFAULT NULL';
|
||||||
} else {
|
} else {
|
||||||
|
Reference in New Issue
Block a user