I want to do this:
Declare @a int; Declare @b int; SET @a,@b = (SELECT StartNum,EndNum FROM Users Where UserId = \'1223\') PRINT @a PRINT @b
Do it like this:
Declare @a int; Declare @b int; SELECT @a=StartNum,@b=EndNum FROM Users Where UserId = '1223' PRINT @a PRINT @b