Bug #59962 Cannot execute queries with 'WITH ROLLUP' modifier
Submitted: 5 Feb 2011 14:29 Modified: 23 Mar 2011 12:51
Reporter: pedro oriani Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.2.31 OS:Windows (7 x64)
Assigned to: CPU Architecture:Any

[5 Feb 2011 14:29] pedro oriani
Description:
I'm tring to execute queries with 'WITH ROLLUP' modifier getting

Error Code: 1064
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

Also Workbench complains for a syntax error on word WITH

no problem executing the query within the command line mysql utility

How to repeat:
execute

select table_schema, table_name, count(*), sum(data_length) from information_schema.tables group by table_schema, table_name with rollup;

Action:
select table_schema, table_name, count(*), sum(data_length) from information_schema.tables group by table_schema, table_name with

Message:
Error Code: 1064
You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
[18 Feb 2011 22:13] Alfredo Kojima
What server version are you executing that against? Did you try executing that query against the same server you're trying from WB, but using command line client?

Here I can execute the query from WB with no problems, except that client-side syntax checker doesn't recognize the with rollup part. But execution works fine.

I'm marking as VERIFIED, because of the syntax checker bug, but as I said, execution works fine for me.
[21 Feb 2011 21:55] Chris Stephens
I can verify this is an issue with the client side syntax checker.  I've encountered the same problem in 5.2.31a.

Queries never execute due to the syntax checker not being aware of ROLLUP.  The same queries execute correctly when using the CLI client.
[23 Feb 2011 16:16] Johannes Taxacher
seems to be a problem with the splitter.
you can workaround for now by using "execute (All or selection)" instead of using "Execute current statement"
[22 Mar 2011 8:31] Valeriy Kravchuk
Bug #60577 was marked as a duplicate of this one.
[23 Mar 2011 12:51] Johannes Taxacher
this is actually a duplicate of Bug #57178