Valid-Time Timestamping - Analytics Database - Teradata Vantage

Temporal Table Support

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2023-10-30
dita:mapPath
eud1628112402879.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
fif1472244754791
lifecycle
latest
Product Category
Teradata Vantage™
A valid-time column specifies the period of time for which the information in a row is effective. Because this information models the real world, such as the period for which a contract is valid:
  • The valid-time period should always be explicitly specified when adding rows to tables that have a valid-time column.
  • An explicit time period should always be specified when making DML modifications to tables that have a valid-time column. This specifies the period of applicability (PA) of the change, which may not exactly match the PV of any row. If the PA of a modification does not match the PV of a row, Vantage determines how to make the change by the relationship between the PA and PV. If the PA and PV overlaps, the modification involves adding new rows to the table to account for the period before and after the change.

Although the PA and PV can be explicitly specified for operations on tables with valid-time columns, Vantage will use default values if these periods are not specified. For valid-time tables, the current time at the time of a row insertion or modification is timestamped as the value of the built-in function TEMPORAL_TIMESTAMP, or TEMPORAL_DATE if the valid-time column has a DATE type.

The value of TEMPORAL_TIMESTAMP or TEMPORAL_DATE for a transaction is the time or date when the first non-locking reference is made to a temporal table, or when the built-in function is first accessed during the transaction.

For more information on TEMPORAL_TIMESTAMP built-in function, see Teradata Vantage™ - SQL Functions, Expressions, and Predicates, B035-1145.