OPERATION PURGE - Teradata Unity

Teradata Unity User Guide

Product
Teradata Unity
Release Number
16.00
Published
March 2017
Language
English (United States)
Last Update
2018-03-29
dita:mapPath
ipb1476817227329.ditamap
dita:ditavalPath
ft:empty
dita:id
B035-2520
lifecycle
previous
Product Category
Analytical Ecosystem

Purpose

Purges completed operations from disk. You can specify the number of hours that must pass before an operation will be purged.

Syntax

OPERATION PURGE[number HOURS]

Parameters

number HOURS
Number of hours required to expire before a completed operation is purged from the database. The default is 168 hours.

Usage Considerations

Unity uses an automatic purging schedule to remove operations from the Unity repository. By default, an automatic purge occurs after 168 hours. You can set the default expiration period using the OperationPurgeTime parameter in CONFIG UPDATE.

Use the CONFIG UPDATE OperationPurgeTime hours; command to set the default number of hours required before an automatic purge of operations. Replace hours with a number to set the default. If you want all operations purged immediately after completion, specify the number of hours as 0 (zero). No Sequencer restart is required to affect your changes.

If a completed operation is the last operation on a valid object or system, the operation is not purged. This ensures that the history for the object is maintained in the Unity repository.

Scenario Description
You freeze TableA and then recover the same TableA. This scenario creates a FREEZE operation and a RECOVER operation. After 168 hours, the FREEZE operation is purged from disk, but the RECOVER operation is not purged because it is the last operation on the table.
You drop TableB using the DROP TABLE command or delete it using the DELETE DATABASE or DELETE USER command. In this scenario TableB is dropped or deleted and at a later time must be reclaimed and removed from the Unity Data Dictionary. In this case, the operations on TableB, including the last operation, are automatically purged when the table_id is reclaimed by the Unity Data Dictionary.

Examples

The following command sets the default expiration time to 100 hours: CONFIG UPDATE OperationPurgeTime 100;