Nontemporal Inserts - Advanced SQL Engine - Teradata Database

Temporal Table Support

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-23
dita:mapPath
cjo1556732840654.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1182
lifecycle
previous
Product Category
Teradata Vantage™
Rows that are closed in transaction time provide a history of all modifications and deletions on tables that have a transaction-time column. The automatic history that tables with transaction time provide can be used for regulatory compliance auditing, so these rows are generally inaccessible to DML modifications. Because NONTEMPORAL DML statements can modify closed rows, the special NONTEMPORAL privilege is required. For more information on the NONTEMPORAL privilege, see NONTEMPORAL Privilege.

The positional assignment list or named list of the INSERT statement can specify the valid-time and transaction-time column values. The values must be assignable to the appropriate columns or the system reports an error.

The following rules apply to the transaction-time column value in an INSERT statement:

  • The beginning bound must not be greater than the value read from the system clock during the insert.
  • The ending bound must be UNTIL_CLOSED or must be less than or equal to the value read from the system clock during the insert.

The SELECT statement of a nontemporal INSERT…SELECT is executed as a nonsequenced SELECT in both the valid-time and transaction-time dimensions. The result rows of the SELECT are inserted into the target table.