Re: psql runs out of memory

From: vittorio <vdemart1(at)tin(dot)it>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: psql runs out of memory
Date: 2005-10-19 16:13:32
Message-ID: 200510191813.33171.vdemart1@tin.it
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Alle 15:07, mercoledì 19 ottobre 2005, Richard Huxton ha scritto:
> Vittorio wrote:
> > In my Pentium 4 box 2GHz with 256 MB of RAM I run a pg server 8.0.3
> > under netbsd 2.0.2 in which among other tables there's a "huge" table
> > letture02 made of 657,000 records and 98 numerical columns.
> >
> > Using psql
> > and the "heavy" view letture24btnondom (see below) I face the following
> > fatal error:
> > ..........
> > # select * from letture24btnondom ;
> > out of
> > memory for query result
>
> How many rows does this return?

All 657,000 records

> How much memory does psql take up when it reports this?

How could I know that amount of memory?

> Do you have any memory limits defined for the user doing the query?

No that I'm aware of.
Could you please specify this point better?

Ciao
Vittorio

> Can you get it to work with something like LIMIT 10 added to the query?
> What about LIMIT 50,100,200 etc?
>
> > Now, it happens that I pg_dumped
> > the database from an original ** freebsd ** installation on another
> > older pc (pentium 3 128 MB) where ** under psql I set up the same query
> > and ran it successfully many times.
> > Besides, via ODBC I can open as a
> > table the letture24btnondom view without any problems.
>
> I'd guess ODBC is using a cursor, so you'll only get a few rows at a
> time. With psql, it'll fetch all the rows at once.

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Csaba Nagy 2005-10-19 16:24:14 How fair is SELECT FOR UPDATE ?
Previous Message Marc G. Fournier 2005-10-19 16:02:15 Re: [pgsql-advocacy] Oracle buys Innobase