.\" XXX standard disclaimer belongs here....
.\" $Header: /private/postgres/ref/postquel/RCS/destroy,v 1.5 1992/07/14 05:54:17 ptong Exp $
.SP DESTROY COMMANDS 6/14/90
.XA 2 Destroy
.uh NAME
.lp
destroy \*- destroy existing classes
.uh SYNOPSIS
.lp
.(l
\fBdestroy\fR classname-1 { \fB,\fR classname-i }
.)l
.uh DESCRIPTION
.lp
.b Destroy
removes classes from the data base.
Only its owner may destroy a class.
A class may be emptied of instances,
but not destroyed,
by using the
.b delete
statement.
.lp
If a class being destroyed has secondary indices on it,
then they will be removed first.
The removal of just a secondary index will not affect
the indexed class.
.lp
This command may be used to destroy a version class
which is not a parent of some other version.
Destroying a class which is a parent of a
version class is disallowed.
Instead, the
.b merge
command should be used.
Moreover, destroying a qclass whose fields are inherited by other classes
is similarly disallowed.  An inheritance hierarchy must be destroyed from 
leaf level to root level.
.lp
The destruction of classes is not reversable.
Thus, a destroyed class will not be recovered
if a transaction which destroys this class fails to commit.
In addition,
historical access to instances in a destroyed class is not possible.
.uh EXAMPLE
.lp
.ft C
/* Destroy the emp class */

destroy emp

/* Destroy the emp and parts classes */

destroy emp, parts
.ft
.uh "SEE ALSO"
.lp
delete(commands),
remove index(commands),
merge(commands).
