I have a query:
select fieldse into #temp01 from table
The problem is, I set up an option
if @variable = option
select * into #temp from #temp01
select * into #temp from #temp03
The problem is query 2 gives me the error:
There is already an object named '#temp' in the database.
it looks like query2 condition 2 is having a problem becasue query 2 option 1has declared #temp table.
Is there a way to surrpress this so that when the proc is compiled I do not get this error?