Bug #49279 WB incorrectly allows default column values for auto-increment columns
Submitted: 1 Dec 2009 17:16 Modified: 5 Jan 2011 14:40
Reporter: Todd Farmer (OCA) Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: Modeling Severity:S3 (Non-critical)
Version:5.2 r4643 OS:Windows (XP)
Assigned to: Mike Lischke CPU Architecture:Any

[1 Dec 2009 17:16] Todd Farmer
Description:
WB allows one to define a column as auto-increment and have a default value.  This is incorrect, and the resulting DDL is rejected by the server.

How to repeat:
Create a table with an INT column.  Define a default value and check the AI box.

Suggested fix:
Disable default values when AI is checked.
[2 Dec 2009 9:32] Susanne Ebrecht
Same here as for bug #49278.

Validation check in Workbench SE already is recognising that auto_increment can't have a default value.

Do you agree with me that this is a feature request?
[15 Nov 2010 15:53] Mike Lischke
Fixed in repository.
[8 Dec 2010 23:40] Johannes Taxacher
fix confirmed in repository
[5 Jan 2011 14:40] Tony Bedford
An entry has been added to the 5.2.31 changelog:

MySQL Workbench allowed an AUTO INCREMENT column to also be assigned a default value in the Table Editor. This resulted in invalid DDL being generated.