SET @t1=1, @t2=2, @t3:=4;
SELECT @t1, @t2, @t3, @t4 := @t1+@t2+@t3;
in the first line where ur defining the a variable using set u can use both = or :=
in the second statement u setting the @t4 to some other variables u have to use := , if u use '= ' it takes as comparison operator