Bug #74801 Forward Engineer of NN Bool default=FALSE generates INSERT w/default=NULL
Submitted: 11 Nov 2014 16:52 Modified: 11 Nov 2014 23:47
Reporter: eric bridges Email Updates:
Status: Verified Impact on me:
None 
Category:MySQL Workbench: Modeling Severity:S3 (Non-critical)
Version:6.2.3.123.12 build 2280 (64 bits) Commun OS:Windows (Win7 64 bits)
Assigned to: CPU Architecture:Any
Tags: default of FALSE, forward engineer, insert, non-null bool

[11 Nov 2014 16:52] eric bridges
Description:
Workbench immediately converts Nun-Null Bool with Default of FALSE value to 0. 
On Forward Engineer with option to generate INSERT statements the zero is interpreted as NULL causing an SQL error.

How to repeat:
Create a Model with a Nun-Null Bool with Default of FALSE. Note the GUI immediately converts this to 0. On Forward Engineer with option to generate INSERT statements the zero is interpreted as NULL causing an SQL error.

Suggested fix:
Either preserve FALSE and TRUE Boolean values and/or check the Non-Null flag before interpreting 0 as Null.
[11 Nov 2014 18:14] MySQL Verification Team
Thank you for the bug report. Please provide a test model project file. Thanks.
[11 Nov 2014 19:28] eric bridges
Small Model with INSERT table saved having NULL in NN BOOL field.

Attachment: GeneratedInsert.mwb (application/octet-stream, text), 6.39 KiB.

[11 Nov 2014 19:29] eric bridges
It appears that the issue if it is one is recreated when the INSERT table has a NULL value for a NN Bool field with default value of FALSE.
[11 Nov 2014 23:47] MySQL Verification Team
Thank you for the feedback.