Bug #63754 'cursor' not supported in MYSQL Workbench
Submitted: 15 Dec 2011 0:38 Modified: 24 Jan 2012 13:31
Reporter: Rene Reitsma Email Updates:
Status: No Feedback Impact on me:
Category:MySQL Workbench: SQL Editor Severity:S3 (Non-critical)
Version:5.2.35 rev 7915 OS:Linux (F15)
Assigned to: CPU Architecture:Any

[15 Dec 2011 0:38] Rene Reitsma
The following code runs fine in the command-line interpreter (mysql  Ver 14.14 Distrib 5.5.18, for Linux (i686) using readline 5.1)

but results in NULL values for 'number' in MYSQL Workbench:

set @num=0;

select @num:=@num+1 as number, some_column

from some_table;

How to repeat:
Try it again :-)
[15 Dec 2011 5:07] Valeriy Kravchuk
Please, try to execute 

set @num=0;
select @num:=@num+1 as number;

together, as two lines, from SQL Editor (not one line, then another)...
[15 Dec 2011 17:34] Rene Reitsma
Putting the commands on a single line has no effect (as, I guess, it should not since the semicolon delimits/separates the statements).
[15 Dec 2011 18:10] Valeriy Kravchuk
Strange. I tried with 5.2.36 on Mac OS X initially. Please, check if newer version, 5.2.36, solves the problem for you.
[15 Dec 2011 18:16] Rene Reitsma
Seems like 5.2.36 is not yet part of the yum update repositories for F15. I guess it will be very soon. I'll keep an eye out for it and will check back here once I I find out.

[23 Dec 2011 22:19] Rene Reitsma
OK, So my F15 system updated to MySQL-Workbench 5.2.36

Here's what I find:

SET @t1=1, @t2=2, @t3:=4;

SELECT @t1, @t2, @t3, @t4 := @t1+@t2+@t3;



(The 'BLOB's are the actual texts displayed :-) )

[24 Dec 2011 13:31] Valeriy Kravchuk
On Mac OS X I've got expected 1,2,4,7 in your example. 

Please, check in SQL Editor options if "Treat BINARY/VARBINARY string as non-binary" option is set. If it is NOT, this may explain "BLOB" in your case.
[25 Jan 2012 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".