Sql Server Drop Temp Table If Exists

[Solved] Sql Server Drop Temp Table If Exists | Sql - Code Explorer | yomemimo.com
Question : sql server drop temp table if exists

Answered by : henry-petersen

IF OBJECT_ID('tempdb..#Results') IS NOT NULL DROP TABLE #Results
GO

Source : | Last Update : Wed, 29 Apr 20

Question : sql server drop temp table if exists

Answered by : kind-kangaroo-jb9m9n2ui4f0

IF OBJECT_ID('tempdb..#Results') IS NOT NULL DROP TABLE #Results

Source : https://stackoverflow.com/questions/659051/check-if-a-temporary-table-exists-and-delete-if-it-exists-before-creating-a-temp | Last Update : Tue, 06 Apr 21

Question : drop temp table if exists

Answered by : bismythos

IF OBJECT_ID('tempdb..#abc') IS NOT NULL DROP TABLE #abc
GO
select * into #abc from District where DistrictId=1
select * from #abc

Source : | Last Update : Sun, 21 Aug 22

Answers related to sql server drop temp table if exists

Code Explorer Popular Question For Sql