Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Checking if a table exists
Message
From
29/02/2008 11:05:34
 
General information
Forum:
Microsoft SQL Server
Category:
Other
Miscellaneous
Thread ID:
01297733
Message ID:
01297741
Views:
17
>if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[MyTable]') and OBJECTPROPERTY(id, N'IsTable') = 1)
>drop table [dbo].[MyTable]

Yes, I saw that one by having done a search. But, the one that Sergey provided as a solution is much better.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Previous
Reply
Map
View

Click here to load this message in the networking platform