Data Types

The table below shows all the built-in general-purpose data types. The alternatives listed in the aliases column can be used to refer to these types as well, however, note that the aliases are not part of the SQL standard and hence might not be accepted by other database engines.

Name Aliases Description
BIGINT INT8 signed eight-byte integer
BOOLEAN BOOL logical boolean (true/false)
BLOB BYTEA variable-length binary data
DATE   calendar date (year, month day)
DOUBLE NUMERIC double precision floating-point number (8 bytes)
INTEGER INT, INT4, SIGNED signed four-byte integer
REAL FLOAT, FLOAT4 single precision floating-point number (4 bytes)
SMALLINT INT2 signed two-byte integer
TIMESTAMP DATETIME time of day (no time zone)
TINYINT   signed one-byte integer
VARCHAR CHAR, BPCHAR, TEXT, STRING variable-length character string