Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id A8F361337B6E for ; Wed, 9 Feb 2011 12:25:07 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 04208-09 for ; Wed, 9 Feb 2011 16:24:59 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mail.postgresql.org (Postfix) with ESMTP id 59AC61337B83 for ; Wed, 9 Feb 2011 12:24:59 -0400 (AST) Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p19GOuuZ026142 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 9 Feb 2011 11:24:56 -0500 Received: from [10.11.8.234] (vpn-8-234.rdu.redhat.com [10.11.8.234]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p19GOtub015142; Wed, 9 Feb 2011 11:24:56 -0500 Subject: Re: Lob Streaming From: Ramesh Reddy Reply-To: rareddy@redhat.com To: Richard Broersma Cc: pgsql-odbc@postgresql.org In-Reply-To: References: <1297090806.3034.4.camel@localhost.localdomain> Content-Type: text/plain; charset="UTF-8" Organization: Red Hat Date: Wed, 09 Feb 2011 10:22:27 -0500 Message-ID: <1297264947.2795.33.camel@localhost.localdomain> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-6.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201102/7 X-Sequence-Number: 10581 Thank you for the info. I am afraid, the code I see in the ODBC driver is not doing streaming. It makes one lo_read call based on the buffer size configured in your client and truncates the rest of the content. What I would like to have seen is, driver making a small length lo_read calls to fill up the buffer size provided by the client, then truncate if the size is larger, not request one huge chuck of read from the server. Ramesh.. On Mon, 2011-02-07 at 08:18 -0800, Richard Broersma wrote: > > > On Mon, Feb 7, 2011 at 7:00 AM, Ramesh Reddy > wrote: > Hi, > > Does psql-odbc driver support lob streaming? I could > successfully get > 'bytea' content, but for large size > GB lobs I am running > into memory > issues. Can you body suggest any alternatives. > > Try using the PostgreSQL contrib module "lo." > > http://www.postgresql.org/docs/9.0/interactive/lo.html > > also see: > http://www.postgresql.org/docs/9.0/interactive/vacuumlo.html > > -- > Regards, > Richard Broersma Jr.