>I am sending a select statement such as:
>
> Select * into #mytemptbl from mytable where {condition}
>
>but the select has no records matching my condition. But I still need the temp
>table created.
>
>Is there a setting to make the table even if the result set is empty?
>
>Peter
That works for me:
Select * into #mytemptbl from mytable where 1=0
SELECT * FROM #mytemptbl
DROP TABLE #mytemptbl
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.