Re: ODBC large binary data support

From: "Inoue, Hiroshi" <h-inoue(at)dream(dot)email(dot)ne(dot)jp>
To: myaddress(at)gmx-topmail(dot)de
Cc: pgsql-odbc(at)postgresql(dot)org
Subject: Re: ODBC large binary data support
Date: 2017-01-08 08:08:07
Message-ID: 4b2ac60f-498f-2a5c-d923-c25f52bee421@dream.email.ne.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

Hi,

On 2017/01/04 23:34, myaddress(at)gmx-topmail(dot)de wrote:
> Hello,
> Recently I successfully stored a 3GB BLOB in PostgreSQL V9.6.1 via
> psql-odbc V09.05.0400, but I was not able to read it afterwards. I got
> the error message "Error reading from large object." for the very
> first SQLGetData call. I debugged it and found out that psql-odbc uses
> "lo_lseek" and "lo_tell" in "lobj.c" which limit the amount of data to
> 2GB (int32 usage). In "lobj.c" there is even the comment /* XXX:
> Should we use lo_lseek64? */ and /* XXX: Should we use lo_tell64? */.
> I temporarily changed the code to use lo_lseek64 and lo_tell64 and I
> could read the 3GB BLOB.

On what OS are you working?
Could you test my code?

> So, could you please change the official psql-odbc to use lo_lseek64
> and lo_tell64?
> I found a discussion about that here:
> https://www.postgresql.org/message-id/CAB7nPqSc7M_wJYjZEfQ7QyBg1mbo3_Dhg0Jeiqx7HpO+46HFTA@mail.gmail.com
> It tells that the 64-bit functions are not supported prior to
> PostgreSQL V9.3. My suggestion would be either dropping the support
> for old versions or a dynamic switch between the 64-bit and the 32-bit
> functions based on the server version.
> I hope that you support that.

Hopefully I would support that.

regards,
Hiroshi Inoue

In response to

Browse pgsql-odbc by date

  From Date Subject
Next Message myaddress 2017-01-08 11:27:03 Re: ODBC large binary data support
Previous Message myaddress 2017-01-04 14:34:57 ODBC large binary data support