Re: Slow query - please help

2011-10-04 Thread Johnny Withers
Can you post the explain extended output of your query? Sent from my iPad On Oct 4, 2011, at 2:45 PM, Neil Tompkins wrote: > Can anyone help me ? > > > Begin forwarded message: > >> From: Tompkins Neil >> Date: 30 September 2011 20:23:47 GMT+01:00 >> To: mark carson >> Cc: "[MySQL]" >> Su

Re: Variables in stored procedure

2011-10-04 Thread luiz rodrigo mottin
yes 2011/10/4 Paul Nickerson > You need a space before the word VALUES > > -- > *From: *"Adam Gerson" > *To: *"luiz rodrigo mottin" > *Cc: *mysql@lists.mysql.com > *Sent: *Tuesday, October 4, 2011 6:00:24 PM > *Subject: *Re: Variables in stored procedure > > > Thank

Re: Variables in stored procedure

2011-10-04 Thread Adam Gerson
Thanks Luiz, That got me closer. I was able to save the stored proc. It should be execute stm; not execute @sql; right? I get this when I try to execute it: 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 ''

Re: Variables in stored procedure

2011-10-04 Thread luiz rodrigo mottin
you can use: set @sql = concat( "INSERT INTO ", TABLENAME, "VALUES ('309', '0', 'statpress_mincap', 'edit_posts', 'yes')"); prepare stm from @sql; execute @sql; 2011/10/4 Adam Gerson > I am getting the error that "TABLENAME" does not exist. How do I get it to > substitute the value stored in TAB

Re: Variables in stored procedure

2011-10-04 Thread Peter Brawley
On 10/4/2011 4:20 PM, Adam Gerson wrote: I am getting the error that "TABLENAME" does not exist. How do I get it to substitute the value stored in TABLENAME, and not the literal string? See the manual page for PREPARE. PB - begin declare v_max int unsigned default 1; declare v_counter

Variables in stored procedure

2011-10-04 Thread Adam Gerson
I am getting the error that "TABLENAME" does not exist. How do I get it to substitute the value stored in TABLENAME, and not the literal string? begin declare v_max int unsigned default 1; declare v_counter int unsigned default 21; declare TABLENAME text; start transaction; while v_counter

Fwd: Slow query - please help

2011-10-04 Thread Neil Tompkins
Can anyone help me ? Begin forwarded message: > From: Tompkins Neil > Date: 30 September 2011 20:23:47 GMT+01:00 > To: mark carson > Cc: "[MySQL]" > Subject: Re: Slow query - please help > > I downloaded version mysql-5.6.2-m5-win32.msi and he table definitions are > below, let me know if

Re: A tidbit for those of us who want to play with InnoDB compression

2011-10-04 Thread Andrew Moore
Nice one Johan, thanks for the info. On Tue, Oct 4, 2011 at 2:17 PM, Johan De Meersman wrote: > As noted in the title, I'm messing about a bit with InnoDB compressed > tables. As such, I found a rather glaring hole in the Internet: how the hell > do you turn compression off again? :-D > > After m

A tidbit for those of us who want to play with InnoDB compression

2011-10-04 Thread Johan De Meersman
As noted in the title, I'm messing about a bit with InnoDB compressed tables. As such, I found a rather glaring hole in the Internet: how the hell do you turn compression off again? :-D After messing about a lot and googling until my fingers hurt, I happened upon this bug report: http://bugs.m

Re: NULL-safe (in)equality <=>; overloaded NULL

2011-10-04 Thread Hal�sz S�ndor
2011/10/02 15:01 +0200, Jigal van Hemert You are not using NULL as the original concept of it was. NULL means that the value is undefined or unknown. That is quite true, especially in a table. But, almost from the beginning, NULL was overloaded: set @m = (select sins from emai