A Data Type Conversion

This appendix contains the following section:

A.1 Data Type Conversion

The gateway converts Teradata data types to Oracle data types as follows:

Table A-1 Data Type Conversions

Teradata Oracle Comment

BLOB

LONG RAW

 

BYTE

RAW

-

BYTEINT

NUMBER(3)

BYTEINT range is -128 to +127

CHAR

CHAR

-

CHAR CHARACTER SET UNICODE

CHAR

-

CLOB

LONG

 

DATE

CHAR(10)

-

DECIMAL

NUMBER(p[,s])

-

FLOAT

FLOAT(24)

with precision <= single precision float

FLOAT

FLOAT(53)

with precision > single precision float

INTEGER

NUMBER(10)

NUMBER range is -2,147,483,648 to 2,147,483,647

INTERVAL

CHAR

-

LONG VARCHAR CHARACTER SET UNICODE

LONG

if Oracle DB Character Set = Unicode. Otherwise, it is not supported.

LONG VARCHAR

LONG

if Oracle DB Character Set = Unicode. Otherwise, it is not supported

SMALLINT

NUMBER(5)

NUMBER range is -32768 to 32767

TIME

CHAR(15)

-

TIMESTAMP

DATE

-

VARBYTE

RAW

with less or equal to 2000 bytes

VARBYTE

LONG RAW

with more than 2000 bytes

VARCHAR

VARCHAR2

If the size is greater than 4000, it is mapped to LONG

VARCHAR() CHARACTER SET UNICO

NVARCHAR2

If the size is 2000 or less, otherwise it is mapped to LONG