Re: Memory leaks in PostgreSQL ODBC driver

From: mlw <markw(at)mohawksoft(dot)com>
To: Hiroshi Inoue <Inoue(at)tpf(dot)co(dot)jp>
Cc: pgsql-odbc(at)postgresql(dot)org
Subject: Re: Memory leaks in PostgreSQL ODBC driver
Date: 2002-06-24 18:14:10
Message-ID: 3D176172.EFAE7422@mohawksoft.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-odbc

Hiroshi Inoue wrote:
>
> mlw wrote:
> >
> > mlw wrote:
> > >
> > > It seems that when you perform a large query against the
> > > postgresql ODBC driver it sucks it all in to memory. If
> > > the query returns more data than you have memory, it fails.
> > > To change this behavior, you set UseDeclareFetch to yes.
>
> Your report is all about UseDeclareFetch mode ?
> If so, I would examine it.

After spending some time and getting real friendly with the ODBC driver, I have
come to realize what I was seeing was not a memory leak, exactly, but a
misunderstanding about how it should work.

My expectation is that if I use UseDeclareFetch mode with a FORWRD_ONLY cursor,
previous results are lost as new results are obtained. I believe the PostgreSQL
ODBC driver is in error, because even with UseDeclareFetch, and a FORWARD_ONLY
cursor, the previous results are not freed, thus preventing the ODBC driver
from querying data sources which can provide more data than can fit in
available RAM.

Is this not correct?

In response to

Responses

Browse pgsql-odbc by date

  From Date Subject
Next Message Booth, Robert 2002-06-24 18:18:05 Unable to identify an ordering operator '<' for type 'xid'
Previous Message Bruce Momjian 2002-06-24 15:29:30 Re: [PATCHES] PostgreSQL 7.2.1 and Sun's C compiler under