By using db<>fiddle, you agree to license everything you submit by Creative Commons CC0.
declare @t table (id int)
insert into @t values (1)
select * from @t
go
select * from @t
id |
---|
1 |
id |
---|
1 |
select * from @t
Msg 1087 Level 15 State 2 Line 1
Must declare the table variable "@t".