[unixODBC-dev] SQL_C integer sizes in 64-bit Linux

Kelly Burkhart pgkrb at kkcsm.net
Wed Mar 2 19:16:29 GMT 2005


Does anyone know what the proper C types are for the SQL_C_* constants 
in ODBC?

The reason I ask is that in the PostgreSQL driver, SQL_C_SLONG maps to a 
long, which on x86-64/gcc is a 64-bit integer.  That leaves no SQL_C 
constant mapping to a 32-bit integer on this platform.

It seems to me the better binding would be SQL_C_SLONG/int4 and 
SQL_C_SBIGINT/int8.

Could any of you ODBC gurus shed some light on this?

TIA,

-K



More information about the unixODBC-dev mailing list