MySQL Forums
Forum List  »  Stored Procedures

Re: PREPARED STATEMENT in a WHILE loop
Posted by: Rick James
Date: July 10, 2012 07:15PM

SELECT @id5 = SELECT id FROM autos ORDER BY id LIMIT 0, 5;
SELECT IF( EXISTS(SELECT * FROM autos WHERE name = 'toyota' AND id <= @id5), 'yes', 'no')

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: PREPARED STATEMENT in a WHILE loop
1575
July 10, 2012 07:15PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.