Bug #80054 Program hangs while running certain queries
Submitted: 19 Jan 2016 17:44 Modified: 24 Sep 2016 6:16
Reporter: Bill Lugo Email Updates:
Status: No Feedback Impact on me:
None 
Category:MySQL Workbench Severity:S5 (Performance)
Version:6.3.5 OS:Windows (Microsoft Windows 7 Enterprise Service Pack 1)
Assigned to: CPU Architecture:Any
Tags: WBBugReporter

[19 Jan 2016 17:44] Bill Lugo
Description:
----[For better reports, please attach the log file after submitting. You can find it in C:\Users\BillLugo\AppData\Roaming\MySQL\Workbench\log\wb.log]

Running queries sometimes causes Workbench to go on an infinite loop. It seems to happen to specific tables, but don't know what the criteria would be. Perhaps it's the amount of data, even though it'll happen with Limit 10. 

How to repeat:
Query specific tables.

Suggested fix:
If it's about pulling too much data, change the response to a warning dialog box with a yes/no option. Better yet, a progress indicator with a cancel option, so that we know that it's working and not frozen.

Using an older version (5.2 CE) helped as a bandaid. Perhaps it has something to do with a newer way in how it handles queries?
[19 Jan 2016 18:03] Bill Lugo
Here's a log excerpt (with some minor changes to names for security purposes):

12:30:38 [INF][        WQE.net]: Launching SQL IDE
12:30:39 [INF][        WQE.net]: SQL IDE UI is ready
12:30:41 [ERR][SqlEditorSchemaTree]: Exception querying metadata from mysql.proc, will fallback to SHOW PROCEDURE: Exception: SELECT command denied to user '-------'@'----.----.---' for table '----'
12:30:52 [ERR][      SqlEditor]: Error querying performance_schema.events_statements_current
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_statements_current'
12:30:52 [ERR][      SqlEditor]: Error querying performance_schema.event_stages_history
: Exception: SELECT command denied to user ''--------'@'----.----.---' for table 'events_stages_history_long'
12:30:52 [ERR][      SqlEditor]: Error querying performance_schema.event_waits_history
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_waits_history_long'
12:36:47 [ERR][      SqlEditor]: Error querying performance_schema.events_statements_current
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_statements_current'
12:36:47 [ERR][      SqlEditor]: Error querying performance_schema.event_stages_history
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_stages_history_long'
12:36:47 [ERR][      SqlEditor]: Error querying performance_schema.event_waits_history
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_waits_history_long'
12:36:56 [ERR][      SqlEditor]: Error querying performance_schema.events_statements_current
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_statements_current'
12:36:56 [ERR][      SqlEditor]: Error querying performance_schema.event_stages_history
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_stages_history_long'
12:36:56 [ERR][      SqlEditor]: Error querying performance_schema.event_waits_history
: Exception: SELECT command denied to user '--------'@'----.----.---' for table 'events_waits_history_long'
[28 Jan 2016 18:57] MySQL Verification Team
Please try version 6.3.6. Thanks.
[29 Feb 2016 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[2 Mar 2016 20:53] Bill Lugo
Tried version 6.3.6, problem still occurs. It does however seem to happen less often. 

-Task Manager needed to stop it
-a table that it always crashes on has the following specs:
--98 columns
---17 of them are varchar(255), 23 are varchar(100), 5 text, rest are small
--table size (est.): 2.9 MiB
--AVG row length: 363
-problem doesn't reproduce consistently with same limit (it occurred with limit 200, did not repeat after restarting with same limit)
--lower limits worked after restart. However, it hung again on limit 300.
--after another restart, worked on lower limits but hangs on limit 200 again
[7 Jul 2016 15:04] Bill Lugo
Using 6.3.7 now and the big query-handling has improved somewhat.

Seems like the bandaid was for the dev's to allow a bigger space for the query. However, I think it also needs:
1. the space limit to be expanded further (assuming that's how it works)
2. whatever the limit is, have some handling in place to catch bigger-than-its-limit queries, like a transaction cancellation option (the Stop Query button doesn't do it).

Anyway, I definitely appreciate the improvement.
[24 Aug 2016 6:16] Chiranjeevi Battula
Hello Bill Lugo,

Thank you for the bug report.
Could you please send us full stack trace to confirm this issue at our end?
steps to get stack trace:

# Microsoft Windows - Please make sure WB path is adjusted per installation.
C> cd "C:\Program Files (x86)\MySQL\MySQL Workbench CE 6.3.7\"
..> MySQLWorkbench.exe -log-level=debug3

Thanks,
Chiranjeevi
[25 Sep 2016 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".