Materialized View Log
Materialized View Log
TRUNCATE TABLE
schema .
table
PRESERVE
PURGE
MATERIALIZED VIEW LOG
DROP
ALL
REUSE
STORAGE
CASCADE
;
Semantics
TABLE Clause
Specify the schema and name of the table to be truncated. This table cannot be
part of a
cluster. If you omit schema, then Oracle Database assumes the table is in your
own schema.
• You can truncate index-organized tables and temporary tables. When you
truncate a
temporary table, only the rows created during the current session are removed.
• Oracle Database changes the NEXT storage parameter of table to be the size of
the last
extent deleted from the segment in the process of truncation.
• Oracle Database also automatically truncates and resets any existing
UNUSABLE indicators
for the following indexes on table: range and hash partitions of local indexes and
subpartitions of local indexes.
• If table is not empty, then the database marks UNUSABLE all nonpartitioned
indexes and all
partitions of global partitioned indexes on the table. However, when the table is
truncated,
the index is also truncated, and a new high water mark is calculated for the
index segment.
This operation is equivalent to creating a new segment for the index. Therefore,
at the end
of the truncate operation, the indexes are once again USABLE.
• For a domain index, this statement invokes the appropriate truncate routine to
truncate the
domain index data.
See Also:
Oracle Database Data Cartridge Developer's Guide for more information on
domain indexes
• If a regular or index-organized table contains LOB columns, then all LOB data
and LOB