Bug #89817 WHERE... clause incomplete after data edit, then "Commit Result Edits"
Submitted: 27 Feb 2018 5:35 Modified: 5 Mar 2018 13:02
Reporter: Gary Trachier Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:6.3.10 OS:MacOS (v10.12.6)
Assigned to: CPU Architecture:x86
Tags: commit result edits, Edit Data, missing where clause

[27 Feb 2018 5:35] Gary Trachier
Description:
When working in the SQL editor, choose "Commit Result Edits" from the "Query" menu sometimes results in the WHERE clause being incomplete in the UPDATE query.

How to repeat:
1) Open connection to a database
2) Execute: SELECT * FROM `mydatabase.mytable`;
3) Edit field(s) in one or more result records (result lines)
4) Choose Commit Result Edits from the Query menu
5) See something like: UPDATE `hartlan6_hhs2`.`ceme_des` SET `owner`='Town of Hartland, Vermont' WHERE `cem_num`='HL013';

Note that the formed UPDATE query includes a complete WHERE clause.

6) Click the Execute then Close buttons to execute the update query.

Now... Repeat steps 3 through 5 above, and you will see something like:
UPDATE `hartlan6_hhs2`.`ceme_des` SET `owner`='Town of Hartland,Vermont' WHERE ;

Notice that the needed qualifier after WHERE is missing.  That is the bug.

Now... If you close the current SQL editor tab/window, then repeat steps 1 through 5 again, it will work correctly again.

Suggested fix:
Unknown.
[5 Mar 2018 13:02] Chiranjeevi Battula
Hello Gary Trachier,

Thank you for the bug report.
I could not repeat the issue at our end using with MySQL workbench 6.3.10 version with MySQL 5.7.21 and 5.6.39 versions.
If you can provide more information, feel free to add it to this bug and change the status back to 'Open'.

Thank you for your interest in MySQL.

Thanks,
Chiranjeevi.
[5 Mar 2018 13:05] Chiranjeevi Battula
Screenshot

Attachment: Bug_89817.png (image/png, text), 101.85 KiB.