According to MySQL manual, table comments are limited to 60 characters. I'm designing the schema in MySQL Workbench, which does not enforce this limit, so I end up with writing more than 60 symbols quite often, and this causes the SQL script to fail. To tell the truth I would be quite happy with table comments being internal to my schema (i.e. not exported to the actual database), but Workbench doesn't allow this either. Hence my question: is there a way to increase maximum length of table comment in MySQL to 255?
+2
A:
According to this bug report, Workbench was fixed in 5.0.18 to not allow comments over 60 characters.
I'm pretty sure there's no way to increase the limit, but if you turn off strict mode (even temporarily while you import) then it should truncate it with a warning instead of throwing an error.
Greg
2008-12-24 12:15:19
No, this is not correct, I have 5.0.28 and the length is still not enforced. In theory I don't complain, it is convenient to have long table annotations, but in practice it breaks my SQL scripts :(
azerole
2008-12-25 09:19:02
A:
It is the first flaw i found in MySQL Workbench. I never used table comments before, but I do like them. Why use embrace (or prepend) the comments using hash tags in the generated SQL script? Won't fail them.
Leonard Wolters
2010-05-16 11:50:46