skip to main content
Part 2: The 32-Bit/64-Bit Drivers : The Sybase Wire Protocol Driver : Data Types
  
Data Types
The following table shows how the Sybase data types are mapped to the standard ODBC data types. Unicode Support lists Sybase to Unicode data type mappings.
Table 35. Sybase Data Type Mapping
Sybase Data Type...
Maps to ODBC Data Type
BIGDATETIME1
SQL_DATETIME
BIGINT 2
SQL_BIGINT
BIGTIME3
SQL_DATETIME
BINARY
SQL_BINARY
BIT
SQL_BIT
CHAR
SQL_CHAR
DATE4
SQL_TYPE_DATE
DATETIME
SQL_TYPE_TIMESTAMP
DECIMAL
SQL_DECIMAL
FLOAT
SQL_FLOAT
IMAGE
SQL_LONGVARBINARY
INT
SQL_INTEGER
MONEY
SQL_DECIMAL
NUMERIC
SQL_NUMERIC
REAL
SQL_REAL
SMALLDATETIME
SQL_TYPE_TIMESTAMP
SMALLINT
SQL_SMALLINT
SMALLMONEY
SQL_DECIMAL
SYSNAME
SQL_VARCHAR
TEXT
SQL_LONGVARCHAR
TIME5
SQL_TYPE_TIME
TIMESTAMP
SQL_VARBINARY
TINYINT
SQL_TINYINT
UNSIGNED BIGINT2
SQL_BIGINT
UNSIGNED INT2
SQL_INTEGER
UNSIGNED SMALLINT6
SQL_SMALLINT
VARBINARY
SQL_VARBINARY
VARCHAR
SQL_VARCHAR

1 Sybase 15.5 and higher only.

2 Sybase 15 and higher only.

3 Sybase 15.5 and higher only.

4 Sybase 12.5.1 and higher only.

5 Sybase 12.5.1 and higher only.

6 Sybase 15 and higher only.

Note: FOR USERS OF SYBASE 12.5 and higher: The Sybase Wire Protocol driver supports extended new limits (XNL) for character and binary columns—columns with lengths greater than 255.
See Retrieving Data Type Information for information about retrieving data types.