MySQL Forums
Forum List  »  PHP

Re: prepared statement syntax problem
Posted by: Dimitris Papageorgiou
Date: September 08, 2015 11:13AM

Peter Brawley Wrote:
-------------------------------------------------------
> MySQL wants the argument in a user variable ...
>
> set @s = 'P%';
> set @sql = 'select ... like @s;
> prepare stmt from @sql;
> etc

Ι have never used user variables in prepared statements...and they just work
Is it that this specific statement requires them?

Options: ReplyQuote


Subject
Written By
Posted
Re: prepared statement syntax problem
September 08, 2015 11:13AM


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.