Bug #35525 Inserts editor does not wrap TEXT or BLOB fields with quotes
Submitted: 24 Mar 2008 17:39 Modified: 8 Apr 2008 14:18
Reporter: David Alsbury Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.0.15 OS:Windows (Vista 32)
Assigned to: Mike Lischke CPU Architecture:Any

[24 Mar 2008 17:39] David Alsbury
Description:
On the "Inserts" tab on the table details panel:

When I open the editor "Open Editor..." I can edit the fields for data inserts.  Some types are not handled well.  TEXT or BLOB types are not wrapped in quotes.

INSERT INTO `...` (...) VALUES (0, 0, 0, 0, 0, 0, '', '', Text content);

Not only will this produce bad inserts, but when you try to change an insert you already created, only the first word will load into the editor.

How to repeat:
Create a table
Create a column that is a TEXT or BLOB type
Open the "Inserts" tab
Press the "Open Editor..." button
Type multiple words separated by spaces into the TEXT/BLOB column
Press "Ok"
Notice generated INSERT statement
Press the "Open Editor..." button again
Notice data that is loaded will only be the first word before the first space
[25 Mar 2008 4:36] Valeriy Kravchuk
Thank you for a bug report.
[27 Mar 2008 13:09] Mike Lischke
I cannot reproduce this problem with the latest code so it seems this has been fixed already. Please try the latest release candidate and let me know if you still see this problem.
[27 Mar 2008 17:32] David Alsbury
5.0.16 Does fix the bug. Thanks!
[28 Mar 2008 17:27] Johannes Taxacher
this was fixed by alfredo on latest insert-editor-changes
[8 Apr 2008 14:18] MC Brown
A note has been added to the 5.0.17 changelog: 

Data in BLOG and TEXT columns defined using the Inserts tab would not be quoted correctly in the resulting SQL.