17.10 - DateTime Data Types - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - Database Design

Product
Advanced SQL Engine
Teradata Database
Release Number
17.10
Release Date
July 2021
Content Type
User Guide
Publication ID
B035-1094-171K
Language
English (United States)
DATE: 4 Bytes (All Platforms)
1Year 1Month Day
AD January 1, 1  —  AD December 31, 9999
TIME: 6 Bytes (Packed64 Platforms) 8 Bytes (Aligned Row Platforms)  
Hour Minute Seconds
hh:mm:ss[.ssssss]
12 Bytes (Aligned Row Platforms) TIMESTAMP:  10 Bytes (Packed64 Platforms)  
Year Month Day Hour Minute Second
yyyy-mm-dd hh:mm:ss
TIME WITH TIME ZONE: 8 Bytes (All Platforms)
Hour Minute Second Timezone_Hour Timezone_Minute
hh:mm:ss.ssssss±hh:mm
TIMESTAMP WITH TIME ZONE: 12 Bytes (All Platforms)
Year Month Day Hour Minute Second Timezone_Hour Timezone_Minute
yyyy-mm-dd hh:mm:ss±hh:mm

The following table indicates the alignment requirements for each of the ANSI/ISO DateTime data types and their respective sizes on packed64 and aligned row platforms. When the size of a stored value for a type differs for packed64 and aligned row platforms, the differing table cells are shaded.

Data Type Packed64 Size (bytes) Aligned Row Size (bytes) Allocated Aligned Row Size (bytes)
DATE  4 4 4
TIME 6 4 8
TIMESTAMP 10 4 12
TIME WITH TIME ZONE 8 4 8
TIMESTAMP WITH TIME ZONE 12 4 12