如何把存储过程查询出来的结果(记录)放到一个临时表里面?
eg:
1:
Create procedure test
As
Select 1 as id, 'abc ' as name
go
Create procedure test
As
Select 1 as id, 'abc ' as name
go
2:
Create table #tmp (a int,b varchar(10))
insert #tmp Exec test
Create table #tmp (a int,b varchar(10))
insert #tmp Exec test
3:
Select * from #tmp
Select * from #tmp