Neoview SQL Reference Manual (R2.3)
DROP TABLE Statement
• “Syntax Description of DROP TABLE”
• “Considerations for DROP TABLE”
• “Example of DROP TABLE”
The DROP TABLE statement deletes a Neoview SQL table and its dependent objects such as
indexes and constraints. See “Database Object Names” (page 206).
DROP [VOLATILE] TABLE table [RESTRICT|CASCADE]
Syntax Description of DROP TABLE
table
is the name of the table to delete.
RESTRICT
If you specify RESTRICT and the table is referenced by a view, or a referential constraint of
another table, or if the table has an active DDL lock, the specified table cannot be dropped.
The default is RESTRICT.
CASCADE
If you specify CASCADE, the table and all of its views, referential constraints, and inactive
DDL locks are dropped. A table that has an active DDL lock (one for which the process that
created it still exists) cannot be dropped even if you specify CASCADE. An active DDL lock
is released when the utility operation that is locking the file completes.
Considerations for DROP TABLE
Authorization and Availability Requirements
To drop a table, you must be the table owner or the schema owner.
Example of DROP TABLE
• This example drops a table:
DROP TABLE mysch.mytable;
• This example drops a volatile table:
DROP VOLATILE TABLE vtable;
100 SQL Statements