Bug #43517 Comment string to long in SQL CREATE script
Submitted: 9 Mar 2009 23:15 Modified: 10 Mar 2009 13:47
Reporter: Ruben Jenster Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.1.7 OS:Linux
Assigned to: CPU Architecture:Any
Tags: CHECKED

[9 Mar 2009 23:15] Ruben Jenster
Description:
A table comment that is longer than 60 characters invalidates the SQL CREATE script.

CREATE  TABLE IF NOT EXISTS `titra`.`developers` (
  `id` INT NOT NULL AUTO_INCREMENT ,
  `name` VARCHAR(45) NOT NULL ,
  `mail` VARCHAR(45) NULL ,
  PRIMARY KEY (`id`))
ENGINE = InnoDB
COMMENT = 'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa';

ERROR 1105 (HY000) at line 27: Too long comment for table 'developers'

How to repeat:
1. Insert a table-comment that is longer than 60 characters
2. create the SQL CREATE script
3. import the SQL CREATE script into the database

Suggested fix:
1. Either limit the comment field to 60 characters
or
2. only insert the first 60 characters of the comment field into the SQL CREATE script
[10 Mar 2009 12:54] Valeriy Kravchuk
Verified just as described. 

Similar problem was fixed on Windows long time ago (in WB 5.0.18 AFAIR), by adding comment validation rule to SE edition. Something like that, at least, should be done on Linux also.
[10 Mar 2009 13:47] Susanne Ebrecht
This is already covert by validation model of SE versions. Also in Workbench 5.1. Workbench 5.1 SE will come out soon.

It is our intention that we don't want to cut the comment because it should be always possible that you will be able to have a longer comment in diagram then in database.