> From: Mark Drew
>
> Depending on the database but in MSSQL is:
> if exists (select * from dbo.sysobjects where id =
> object_id(N'[dbo].[que_log]') and OBJECTPROPERTY(id, N'IsUserTable') =
> 1)
> drop table [dbo].[que_log]
> GO

Why not use INFORMATION_SCHEMA.TABLES rather than sysobjects

If exists (select * from INFORMATION_SCHEMA.TABLES where table_name =
'YourTable')

Much more readable
[Todays Threads] [This Message] [Subscription] [Fast Unsubscribe] [User Settings]

Reply via email to