Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 MYSQL problem

Author  Topic 

kneel
Starting Member

36 Posts

Posted - 2007-10-16 : 04:45:35
Hello All,

How to write following query which is in SQL Server 2000 in MYSQL ?

DECLARE @value INT
SELECT @value = GroupID FROM GROUPS


thanks in advance

--kneel

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-10-16 : 04:54:55
quote:
Originally posted by kneel

Hello All,

How to write following query which is in SQL Server 2000 in MYSQL ?

DECLARE @value INT
SELECT @value = GroupID FROM GROUPS


thanks in advance

--kneel


SET @value:= GroupID FROM GROUPS

This is SQL Server Forum. You should post your mysql questions at www.mysql.com

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

kneel
Starting Member

36 Posts

Posted - 2007-10-16 : 05:10:20
Thanks a lot
it works..I will keep in mind while posting :)

--kneel
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-10-16 : 06:59:46
quote:
Originally posted by kneel

Thanks a lot
it works..I will keep in mind while posting :)

--kneel


Note that in MYSQL you dont need to declare a variable

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

blindman
Master Smack Fu Yak Hacker

2365 Posts

Posted - 2007-10-16 : 08:53:41
quote:
This is SQL Server Forum. You should post your mysql questions at www.mysql.com
...or the MYSQL forum on www.dbforums.com

e4 d5 xd5 Nf6
Go to Top of Page
   

- Advertisement -