MySQL Forums
Forum List  »  MySQL Workbench

Re: mysql tools and mysql version
Posted by: Roland Bouman
Date: February 12, 2008 04:10AM

Thanks!

The problem is the missing quotes around N here:

`kz_aktiviert` CHAR(1) NOT NULL DEFAULT N ,
`kz_gesperrt` CHAR(1) NOT NULL DEFAULT N ,

To prevent this from happening, be sure to use single quotes to enclose the default value. So in the WB column editor, enter 'N' rather than N.

It might seem strange to make the user responsible for entering the quotes, but there is actually a good reason for that. If the quotes would not be entered, and WB would assume N in the field should be translated to 'N' for string type columns, then it would be impossible to distringuish between NULL and 'NULL'.

There maybe other ways to solve this, but for now, you should simply enclose your default value in single quotes.

Kind regards,

Roland Bouman
http://rpbouman.blogspot.com/

Options: ReplyQuote


Subject
Views
Written By
Posted
3363
February 11, 2008 04:18AM
2316
February 11, 2008 06:40AM
2794
February 12, 2008 03:27AM
Re: mysql tools and mysql version
2321
February 12, 2008 04:10AM
2285
February 12, 2008 04:54AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.