Bug #20567 Query errors (1064) without final newline, ResultSets switch truncates them.
Submitted: 20 Jun 2006 10:18 Modified: 5 Dec 2006 13:35
Reporter: Richard Joseph Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Query Browser Severity:S3 (Non-critical)
Version:1.1.20 OS:Windows (Windows XP)
Assigned to: Mike Lischke CPU Architecture:Any
Tags: Source Editors

[20 Jun 2006 10:18] Richard Joseph
Description:
Hi,
This is not of amazing importance, although it is quite annoying.

When I write a query, if that query is not terminated by a newline (i.e. a blank line), I get an error message (1064). Adding the newline (hitting enter) allows the query to proceed. However, when I switch between Resultset panes, the newline is remove, meaning I cannot immediately execute my query without re-adding the newline.

Adding multiple newlines does not work either, as each successive return to a particular Resultset pane will remove a line, one at a time (eventually ending in there being no newlines with the query and the error re-occuring).

Thanks

How to repeat:
Write a query big enough to file the initial query window (4-5 lines). Make sure the last line of the query is on the last line of the window/pane.

Execute it. You should be greeted by an error.

Add a new line to the query, creating a blank line at the end.

Re-run the query. It should work.

Open a new Resultset pane and swith to it. Then switch back to the initial query.

The original newline you added should now have been removed and the query will fail to execute.

Suggested fix:
Allow the query to execute without the need for a newline.
[20 Jun 2006 10:19] Richard Joseph
Corrected Version number
[20 Jun 2006 10:28] Valeriy Kravchuk
Please, send the exact problematic query. I was not able to repeat the behaviour you described with my queries.
[20 Jun 2006 11:00] Valeriy Kravchuk
Verified just as described with your query (and empty tables with columns it uses). It is a bug.
[5 Dec 2006 13:35] Mike Lischke
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at

    http://dev.mysql.com/doc/en/installing-source.html