hey lets say we have 3 tables tbl1,tbl2,tbl3 and using the below query you can view the data
select * from tbl1
select * from tbl2
select * from tbl3
my question is that can you eliminate repetition by using variables? like for example
DECLARE @x as varchar(60)
set @x = tbl1
set @x = tbl2
set @x = tbl3
select * from @x
Go
I hate retyping the exact query does anyone know a way to make the query work I think it would save me loads of time. thanks