I have a few variables declared, what I need is to set the variables to some values from a single select from a temp table.
, @CurrentUserID varchar(40)
I would like to do something like this
SELECT @Action , @CurrentUserID = OpsAction, OpsUser from #tmpGroup where ID= @ID and VersionNumber = @CurrentVersionNo
Is there a way to set multiple values from a single select
I know this works
SELECT @Action = OpsAction from #tmpGroup where ID= @ID and VersionNumber = @CurrentVersionNo
but want to avoid repeating the select