Bug #392 | Problem With Auto_increment/Default Value in MySQL 4.1 | ||
---|---|---|---|
Submitted: | 7 May 2003 16:16 | Modified: | 1 Jun 2003 14:34 |
Reporter: | Timothy Crider | Email Updates: | |
Status: | Won't fix | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 4.1 | OS: | Linux (Red Hat 8.0) |
Assigned to: | Arjen Lentz | CPU Architecture: | Any |
[7 May 2003 16:16]
Timothy Crider
[8 May 2003 19:03]
MySQL Verification Team
Thanks you for the bug report. The behavior of 4.1.XX is different than 4.0.XX and 3.23.XX when is used the default value with an auto_increment column. This was added with the changeset: 1.1494.38.1 2003/03/26 /sql/sql_parse.cc if (default_value) { ..... #ifdef MYSQL41000 else if (type_modifier & AUTO_INCREMENT_FLAG) { net_printf(&thd->net, ER_INVALID_DEFAULT, field_name); DBUG_RETURN(1); } #endif So the bug should be: 1- Isn't documented that typing a default value for auto_increment column isn't more supported on servers 4.1.XX. 2- The message error isn't well descriptive.
[1 Jun 2003 14:34]
Michael Widenius
Thank you for your bug report. This issue has been addressed in the documentation. The updated documentation will appear on our website shortly, and will be included in the next release of the relevant product(s). I have now updated the CREATE and upgrading to 4.1 manual sections about this.
[28 Apr 2005 2:07]
LifeNT koson
the auto_increment colum can only accept default value as "default null",yeah,can only accept "null" as default value,all the other value is not invalied.