Oracle7 Server Administrator's Guide

Contents Index Home Previous Next

Dropping Tables

To drop a table, the table must be contained in your schema or you must have the DROP ANY TABLE system privilege.

To drop a table that is no longer needed, use the SQL command DROP TABLE. The following statement drops the EMP table:

DROP TABLE emp;

If the table to be dropped contains any primary or unique keys referenced by foreign keys of other tables and you intend to drop the FOREIGN KEY constraints of the child tables, include the CASCADE option in the DROP TABLE command, as shown below:

DROP TABLE emp CASCADE CONSTRAINTS;

Warning: Before dropping a table, familiarize yourself with the consequences of doing so:


Contents Index Home Previous Next