thanks, got it. Bret. One more question. If sp2 call another sp3, if this #table1 available for sp3 if I doing thing like:
sp1.
CREATE TABLE #table1 (......)
go
create proc sp3
as
begin
....
delete from #table1
INSERT INTO #table1
......
end
create proc sp2
as
begin
....
delete from #table1
INSERT INTO #table1
exec sp3
......
end
go
drop table #table1
go
create proc sp1
as
begin
CREATE TABLE #table1 (......)
Exec sp2
end