NonStop SQL/MP Reference Manual

Table Of Contents
NonStop SQL/MP Reference Manual142115
P-38
Examples—PURGEDATA
After pressing the Break key, you can restart a PURGEDATA operation by
reentering the same command. The following sequence is permissible:
>> PURGEDATA *.*.* FROM CATALOG $VOL1.SUBV1;
>> (press the Break key)
>> PURGEDATA *.*.* FROM CATALOG $VOL1.SUBV1;
You could also use FC to reenter the PURGEDATA command.
PURGEDATA operations that involve many partitions, especially remote partitions,
can often cause many occurrences of error 73 (The disk file or record is locked) or
error 40 (The operation timed out) when the operation attempts to update file labels
and catalog entries.
If the PURGEDATA operation fails, PURGEDATA leaves the object or file marked
corrupt. To clear the corrupt flag, correct whatever problem caused the operation to
fail and repeat the PURGEDATA command.
Version management consideration
PURGEDATA does not apply to audited tables that reside on nodes running versions
of NonStop SQL/MP software earlier than version 300.
PURGEDATA and indices
If a file has dependent indices, you must first drop them, purge the data, alter the
table to drop any partitions, then re-create the indices.
Examples—PURGEDATA
The following command clears all tables and files other than catalog tables or SQL
program files on subvolume $VOL1.PERSNL and lists the names of the cleared
files and tables:
>> PURGEDATA $VOL1.PERSNL.*;
The confirmation message might look like this:
DATA ARE PURGED FROM TABLE $VOL1.PERSNL.DEPT
DATA ARE PURGED FROM TABLE $VOL1.PERSNL.JOB
DATA ARE PURGED FROM TABLE $VOL1.PERSNL.EMPLOYEE
DATA ARE PURGED FROM 3 OBJECT(S)
The following command clears data from the partition $NY.SALES.ACCTS without
clearing other partitions of the table:
>> PURGEDATA $NY.SALES.ACCTS, PARTONLY NO LISTALL;
DATA ARE PURGED FROM 1 OBJECTS(S)