Description:
When exporting a table via SHOW CREATE TABLE, the auto increment property on the related column is left off when SQL mode is set to MYSQL40
version 5.0.18
version comment Source distribution
version compile machine i686
version compile os pc-linux-gnu
[root@server ~]# uname -a
Linux hostname.com 2.6.16-1.2096_FC4 #1 Wed Apr 19 15:27:46 EDT 2006 i686 athlon i386 GNU/Linux
How to repeat:
mysql> show create table domains;
CREATE TABLE `domains` (
`id` int(10) unsigned NOT NULL auto_increment,
`wordID` int(10) unsigned NOT NULL,
`domain` varchar(66) NOT NULL,
`status` tinyint(4) NOT NULL,
`date` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
mysql> set sql_mode='MYSQL40';
mysql> show create table domains;
CREATE TABLE `domains` (
`id` int(10) unsigned NOT NULL,
`wordID` int(10) unsigned NOT NULL,
`domain` varchar(66) NOT NULL,
`status` tinyint(4) NOT NULL,
`date` timestamp NOT NULL,
PRIMARY KEY (`id`)
) TYPE=MyISAM