Hello all sql expert,
Is that necessary to have drop table #tmptbl at
the of the query or stored proc if you already have
the if statement on the header to drop the #tmptbl?
For example:
IF OBJECT_ID ('tempdb.dbo.#tmptbl') IS NOT NULL DROP TABLE #tmptbl
SELECT A,B,C
INTO #tmptbl
FROM A_TABLE
DROP TABLE #tmptbl (Is this necessary?)
OR the above If statement already covers to clean up the #tmptbl?
Thanks guys