Bug #82929 Workbench is only retaining first query executed in History
Submitted: 9 Sep 2016 17:11 Modified: 6 Apr 2018 19:46
Reporter: Thomas Johnson Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:6.3.7 OS:Microsoft Windows (Windows 10 Pro version 1511)
Assigned to: CPU Architecture:Any
Tags: Workbench History first query

[9 Sep 2016 17:11] Thomas Johnson
Description:
Workbench is only retaining first query executed in History.

How to repeat:
1) Start Workbench
2) open a SQL Query to a database
3) run the following query: select 1, now()
4) run the following query in the same SQL tab: select 2, now()
5) run the following query in the same SQL tab: select 3, now()
6) Go to history and view todays log.  You will only see select 1, now() in the log.
7) Open a FileExplorer and go to: %appdata%\MySQL\Workbench\sql_history
8) Open todays file.  will only see select 1, now() in the log.
 

Suggested fix:
Every quesy should be written the to log file.
[9 Sep 2016 19:03] Miguel Solorzano
Thank you for the bug report.
[9 Sep 2016 19:23] Thomas Johnson
I found if I open a NEW SQL Tab, the first query on that tab is also saved, but subsequent queries are not.
[6 Apr 2018 19:46] Christine Cole
Posted by developer:
 
Fixed as of the upcoming MySQL Workbench 8.0.11 release, and here's the changelog entry:

When multiple queries were executed, only the first query was displayed in
the history output area or written to the sql_history log file.

Thank you for the bug report.