Re: ODBC : SQLGetData question - Mailing list pgsql-odbc

From Dev Kumkar
Subject Re: ODBC : SQLGetData question
Date
Msg-id CALSLE1Pw2p7t+BpfTZ=UXqMDjB4u7isYcG7FZ7Q4XmKwLpKerw@mail.gmail.com
Whole thread Raw
In response to Re: ODBC : SQLGetData question  (Nick Gorham <nick@lurcher.org>)
List pgsql-odbc
On Wed, May 14, 2014 at 3:38 PM, Nick Gorham <nick@lurcher.org> wrote:
We are deploying the driver as it is and not compiling it in-house currently.
Yes, the platform is 64-bit.

In that case compile the application with the same setup as the driver.

Thanks again for the help here. I think as you mentioned before the application expects sizeof( SQLLEN ) == 8 and the driver sizeof( SQLLEN ) == 4 which results into this issue.

Actually tried to initialize my_buff_len = SQL_NULL_DATA;
The next printf correctly prints the value of my_buff_length as -1.

Only after SQLGetData(my_stmt, my_col_no, SQL_C_CHAR, &my_max_len, 0, &my_buff_len) the value of my_buff_len becomes 429496729.

Is it possible the ODBC header files on machine where am compiling application is having issues or as you mentioned before its the issue with the environment with which ODBC driver was compiled?

Am downloading the driver from here:  9.2.1 ODBC Driver

http://yum.postgresql.org/9.3/redhat/rhel-5.0-x86_64/

 

Regards...

pgsql-odbc by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: psqlODBC text length with no records
Next
From: Adrian Klaver
Date:
Subject: Re: psqlODBC text length with no records