if object_id(N'tempdb..#MaxTransaction') is not null drop table #MaxTransaction
DROP TABLE IF EXISTS #lu_sensor_name_19
CREATE TABLE #lu_sensor_name_19...
IF OBJECT_ID(N'tempdb..#RequestingBrokers') IS NOT NULL
BEGIN
DROP TABLE #RequestingBrokers
END
GO
IF OBJECT_ID('tempdb.dbo.#SeatStatus', 'U') IS NOT NULL
DROP TABLE #SeatStatus;
-- 'U' is object type : U = Table (user-defined)
IF OBJECT_ID('tempdb..#lu_sensor_name_19') IS NOT NULL
BEGIN
DROP TABLE #lu_sensor_name_19
END
CREATE TABLE #lu_sensor_name_19...
IF OBJECT_ID('tempdb..#abc') IS NOT NULL DROP TABLE #abc
GO
select * into #abc from District where DistrictId=1
select * from #abc