17.05 - Example: Creating a Sequenced View on a Temporal Table Using a Business Calendar Function - Teradata Database

Teradata Vantage™ - Temporal Table Support

prodname
Advanced SQL Engine
Teradata Database
vrm_release
17.00
17.05
created_date
June 2020
category
Programming Reference
featnum
B035-1182-170K

The following statement employs a business calendar function in an AS OF clause to define a view that shows insurance policies valid at the beginning of the current year.

CREATE VIEW ValidePoliciesOnJan1 AS
  VALIDTIME AS OF TD_YEAR_BEGIN(CURRENT_DATE) SELECT * FROM Policy;