Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
khufiamalik
Posting Yak Master
120 Posts |
Posted - 2008-09-02 : 05:17:38
|
| Hello All,I want to create a SP that will create some values and place these values in a Table, and this table should be returned to the caller SP.and before the completion of SP this table should be dropped also.Can any one give me syntax or hint:Thanks in advance |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2008-09-02 : 05:40:58
|
CREATE PROC sp1AScreate table #mytable (i int, j int)insert #mytableEXEC sp2Gocreate proc sp2asselect 1, 2 gocreate proc sp3ascreate table #anothertable ( a int, b int, c int)insert #anothertableselect col1, col2, col3 from a_sourceselect a, b, c from #anothertabledrop table #anothertablego E 12°55'05.63"N 56°04'39.26" |
 |
|
|
|
|
|