Data Type Definition
Keyword 1
|
HAWQ Data Type
|
Description
|
Data Type Returned
|
---|---|---|---|
BIGINT
|
INT8
|
Large signed, exact
whole number.
|
BIGINT
|
CHAR(n)
|
CHAR(n)
|
Fixed-length character
string.
|
CHAR(n)
|
DATE
|
DATE
|
Date values.
|
DATE
|
DECIMAL|NUMERIC(p,s)
|
DECIMAL(p,s)
|
Signed, fixed-point
decimal number.
|
DECIMAL|NUMERIC(p,s)
|
DOUBLE
|
DOUBLE
|
Floating-point number.
|
DOUBLE
|
FLOAT(p)
|
FLOAT8(p)
|
Floating-point number.
|
FLOAT(p)
|
INTEGER
|
INTEGER
|
Regular signed, exact
whole number.
|
INTEGER
|
REAL
|
REAL
|
Floating-point number.
|
REAL
|
SMALLINT
|
INT8
|
Small signed, exact
whole number.
|
SMALLINT
|
TIME(p)
|
TIME(p)
|
Time value in hours,
minutes, and seconds.
|
TIME(p)2
|
TIMESTAMP(p)
|
TIMESTAMP(p)
|
Date and time value.
|
TIMESTAMP(p)
|
VARBINARY(n)
|
BYTEA
|
Varying-length binary
string.
|
VARBINARY(n)
|
VARCHAR(n)
|
VARCHAR(n)
|
Varying-length character
string.
|
VARCHAR(n)
|
1The CT_PRESERVE= connection argument, which controls how data types are mapped, can affect whether a data type can be defined. The values FORCE (default) and FORCE_COL_SIZE do not affect whether a data type can be defined. The values STRICT and SAFE can result in an error if the requested data type is not native to the data source, or the specified precision or scale is not within the data source range. | |||
2Due to the ODBC-style interface that is used to communicate with the HAWQ server, fractional seconds are lost in the data transfer from server to client. |