can somebody tell me why the value of Val is 5 (and not 10) after this update?
create table #tmp(Val int)
insert into #tmp values(1)
declare @i int = 10
update #tmp set Val = @i, @i = 5
select * from #tmp
can somebody tell me why the value of Val is 5 (and not 10) after this update?
create table #tmp(Val int)
insert into #tmp values(1)
declare @i int = 10
update #tmp set Val = @i, @i = 5
select * from #tmp