List:General Discussion« Previous MessageNext Message »
From:Gleb Paharenko Date:January 23 2006 2:48pm
Subject:Re: assigning variable without printing result?
View as plain text  
Hello.

It is not clear for what does it mean without printing the result. Could
you provide an example. If you don't want the variable to be in the
column listing you can use such a technique:
 select * from ab where @variable:=1 and (other conditions).

Do not forget about SET syntax (it doesn't produce any result set at all).



Jacek Becla wrote:
> Hi,
> 
> Can someone tell me how to assign result to a variable
> inside SELECT without printing the result?
> 
> Thanks,
> Jacek


-- 
For technical support contracts, goto https://order.mysql.com/?ref=ensita
This email is sponsored by Ensita.NET http://www.ensita.net/
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /    Gleb Paharenko
 / /|_/ / // /\ \/ /_/ / /__   Gleb.Paharenko@stripped
/_/  /_/\_, /___/\___\_\___/   MySQL AB / Ensita.NET
       <___/   www.mysql.com
Thread
assigning variable without printing result?Jacek Becla22 Jan
  • Re: assigning variable without printing result?Gleb Paharenko23 Jan
    • Comparing 2 TablesAM COMS23 Jan
      • Re: Comparing 2 TablesSGreen23 Jan
      • Re: Comparing 2 TablesPeter Brawley23 Jan