ODBC Driver for PostgreSQL

Supported Data Types - ODBC Driver for PostgreSQL

Data Type Mapping

The Devart ODBC Driver for PostgreSQL supports all PostgreSQL data types.

The following table describes how the PostgreSQL data types are mapped to the ODBC data types.

PostgreSQL Data Types ODBC Data Types

TEXT

SQL_LONGVARCHAR

CHARACTER VARYING

SQL_VARCHAR

CHARACTER

SQL_CHAR

BIT

SQL_BIT

SMALLINT

SQL_SMALLINT

INTEGER

SQL_INTEGER

BIGINT

SQL_BIGINT

OID

SQL_INTEGER

SMALLSERIAL

SQL_SMALLINT

SERIAL

SQL_INTEGER

BIGSERIAL

SQL_BIGINT

BYTEA

SQL_LONGVARBINARY

NUMERIC

SQL_NUMERIC

DECIMAL

SQL_DECIMAL

REAL

SQL_REAL

DOUBLE PRECISION

SQL_DOUBLE

DATE

SQL_TYPE_DATE

TIME

SQL_TYPE_TIME

TIMESTAMP

SQL_TYPE_TIMESTAMP

INTERVAL YEAR

SQL_INTERVAL_YEAR

INTERVAL MONTH

SQL_INTERVAL_MONTH

INTERVAL DAY

SQL_INTERVAL_DAY

INTERVAL HOUR

SQL_INTERVAL_HOUR

INTERVAL MINUTE

SQL_INTERVAL_MINUTE

INTERVAL SECOND

SQL_INTERVAL_SECOND

INTERVAL YEAR TO MONTH

SQL_INTERVAL_YEAR_TO_MONTH

INTERVAL DAY TO HOUR

SQL_INTERVAL_DAY_TO_HOUR

INTERVAL DAY TO MINUTE

SQL_INTERVAL_DAY_TO_MINUTE

INTERVAL DAY TO SECOND

SQL_INTERVAL_DAY_TO_SECOND

INTERVAL HOUR TO MINUTE

SQL_INTERVAL_HOUR_TO_MINUTE

INTERVAL HOUR TO SECOND

SQL_INTERVAL_HOUR_TO_SECOND

INTERVAL MINUTE TO SECOND

SQL_INTERVAL_MINUTE_TO_SECOND

© 2015-2022 Devart. All Rights Reserved. Request Support ODBC Forum Provide Feedback