HOW TO check if a temporary table exists before DROPping
To check if a temporary table already exists before DROPping, use
If Object_Id('tempdb..#big') is Not Null
Drop table #big
To check if a temporary table already exists before DROPping, use
If Object_Id('tempdb..#big') is Not Null
Drop table #big
Comments
Post a Comment