views:

172

answers:

1

Hi,

I am actually dropping a temporary table in Database. I have to delete only if it exists in the Database. Please let me know how to check if a table exists in Data base.

+3  A: 
if object_id('tempdb..#myTempTable') is not null
    drop table #myTempTable
Steven Robbins