DROP TABLE

Remove one or more tables.

Syntax
      DROP TABLE database. [schema].table [,...n ] [;]
      DROP TABLE [schema.] table [,...n ] [; ]

Key
   table    The table to be dropped

Drop Table will delete all data, indexes, triggers, constraints, and permissions for the table(s).
Views and stored procedures that reference the table should be dropped with DROP VIEW/ PROCEDURE.

Examples

DROP TABLE MyTable1;
DROP TABLE MyDB.dbo.MyTable2 ;
DROP TABLE #MyTempTable;

"I've had a wonderful time, but this wasn't it." - Groucho Marx

Related commands:

CREATE TABLE
ALTER TABLE
Equivalent Oracle command: DROP TABLE


 
Copyright © SS64.com 1999-2019
Some rights reserved