Chapter 4 Working With ANSI Valid-Time Tables - Teradata Database

SQL External Routine Programming

Product
Teradata Database
Release Number
15.10
Language
English (United States)
Last Update
2018-10-06
dita:id
B035-1147
lifecycle
previous
Product Category
Teradata® Database

Valid time is the time period during which the information in a row is in effect or true for purposes of real-world application. (ANSI calls this period “application time.”) Valid-time columns store information such as the time an insurance policy or contract is valid, the length of employment of an employee, or other information that is important to track and manipulate in a time-aware fashion.

Use valid-time tables when the information in table rows is delimited by time, and for which row information should be maintained, tracked, and manipulated in a time-aware fashion.

Valid-time tables are most appropriate when changes to rows occur relatively infrequently. To represent attributes that change very frequently, such as a point of sale table, an event table is preferable to a valid-time table. Temporal semantics do not apply to event tables.

Note: The material in this chapter covers only the syntax, rules, and other details that apply to ANSI temporal tables. The syntax diagrams presented are extracts of the full diagrams that focus on the temporal syntax.

Most of the existing rules and options that apply to conventional, nontemporal versions of the SQL statements discussed here also apply to the temporal statements. The nontemporal rules and options are not repeated here. For more information on conventional, nontemporal SQL DDL and DML statements, see SQL Data Definition Language and SQL Data Manipulation Language.