Teradata support variety of datatypes for storing numbers,character & date fields

Teradata Basic Datatypes

Teradata support many datatypes for data storage and processing. Some of them are described below.

Datatype Description
Char(n) Represents a fixed length character string of upto n charater.
Varchar(n)Represents a variable length character string of length 0 to n.
ClobRepresents a variable length Character Large Object (CLOB) of length 0 to n.
Graphic(n)This is an alias for 'Char(n) Character Set Graphic'.
Vargraphic(n)This is an alias for 'Varchar(n) Character Set Graphic'.
JSON(n)Represents a variable length JavaScript Object Notation (JSON) of length 0 to n.
ByteIntRepresents a 8-bit (1-byte) integer.
Range: -128 to 127
BigIntRepresents an 64-bit (8-byte) integer.
Range: -9,223,372,036,854,775,808 to 9,223,372,036,854,775,80
Decimal(m,n)Represents a decimal number with maximum precision of 38 but it can range from 1 to 38. The scale can range from 0 to 38 but it must be less than or equal to the precision.
DoubleDouble Represents a 64-bit double-precision number.
Range: ±2.226 x 10-308 to ±1.797 x 10308
IntegerRepresents a 32-bit (4-byte) integer.
Range: -2,147,483,648 to 2,147,483,647.
NumberRepresents a fixed or floating point decimal.
For fixed decimals the maximum precision is 38 and the scale can range from 0 to 38. The scale must be less than or equal to the precision.
For floating decimals the mantissa can contain up to 38 digits, and the exponent can range from -130 to 125.
SmallIntRepresents a 16-bit (2-Byte) integer.
Range: -32,768 to 32,767
DateDate data type has Year, Month and Day components.
The range of values are from January 1, 01 through December 31, 9999.
Time(n)Time data type has Hour, Minute, Second and Fractional Second components.
'n' represent the number of digits for the Fractional-Second component ranges from 0 to 6. The Teradata Database defaults the fractional seconds to 6 digits.
The range of values are from 00:00:00.000000 through 23:59:59.999999.
Time(n) With Time Zone Time With Time Zone data type has Hour, Minute, Second, Fractional-Second, Time Zone Hour and Time Zone Minute components.
Time Zone range of values are from -12:59 through +14:00.
Timestamp(n)Timestamp data type has Year, Month, Day, Hour, Minute, Second and Fractional-Second components.
The range of values are from January 1, 01 00:00:00.000000 through December 31, 9999 23:59:59.999999.
Timestamp(n) With Time ZoneTimestamp data type has Year, Month, Day, Hour, Minute, Second, Fractional-Second, Time Zone Hour and Time Zone Minute components.
The Time Zone range of values are from -12:59 through +14:00.


Binary String Data
Datatype Description
Byte(n) Specifies a fixed length column of length 'n' for binary string data. The maximum value for 'n' is 64000.
VarByte(n) Specifies a varying length column of length 'n' for binary string data. The maximum value for 'n' is 64000.
Blob Specifies a variable length Binary Large Object (BLOB).


The Teradata Database supports 5 Server Character Sets
Character Set NameDescription
LATINFixed 8-bit characters from the ASCII ISO 8859 Latin1 or ISO 8859 Latin9 repertoires.
UNICODEFixed 16-bit characters from the UNICODE 4.1 standard.
GRAPHICFixed 16-bit UNICODE characters defined by IBM Corporation for DB2.
KANJI1Mixed single-byte/multi-byte characters as defined by KanjiEBCDIC, KanjiShift-JIS, or KanjiEUC, depending on the current Session Character Set.
KANJISJISMixed single-byte/multi-byte characters intended for Japanese applications that rely on KanjiShiftJIS characteristics.