Example: Converting Period Data to a DATE Value - Advanced SQL Engine - Teradata Database

SQL Data Types and Literals

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
17.00
Published
June 2020
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
zsn1556242031050.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1143
lifecycle
previous
Product Category
Teradata Vantage™

Assume pd is a PERIOD(DATE) column in table t with a value of 
PERIOD '(2005-02-02, 2005-02-03)'.

In the following example, a PERIOD(DATE) column is cast as DATE. The result is the beginning bound of the column.

SELECT CAST(pd AS DATE) FROM t;

The following is returned:

2005-02-02