Re: BUG #2481: select from table's join with geometries doesn't go

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Michael Fuhr <mike(at)fuhr(dot)org>
Cc: Emilia Venturato <venturato(at)faunalia(dot)it>, pgsql-bugs(at)postgresql(dot)org, strk(at)refractions(dot)net
Subject: Re: BUG #2481: select from table's join with geometries doesn't go
Date: 2006-06-16 14:18:04
Message-ID: 16566.1150467484@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Michael Fuhr <mike(at)fuhr(dot)org> writes:
> That's a lot of data -- are you aware that psql (via libpq) fetches
> the entire result set before displaying it? In most cases 18444
> rows wouldn't be a problem, but with rows that wide it becomes a
> big problem because the client has to store it all in memory. I
> wonder if that's causing psql to segfault, although I'd expect a
> graceful error like "out of memory for query result" unless maybe
> psql consumes so much memory that the OS has problems.

I'm wondering the same --- psql is definitely designed to survive
out-of-memory:

regression=# select * from tenk1 a, tenk1 b limit 2000000;
-- time passes ...
out of memory for query result
regression=#

Emilia might have found some corner case where it doesn't, though;
perhaps a malloc call that's not error-checked. A stack trace from
the psql core dump would be useful.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Emilia Venturato 2006-06-16 14:29:16 Re: BUG #2481: select from table's join with geometries doesn't go
Previous Message Michael Fuhr 2006-06-16 13:58:10 Re: BUG #2481: select from table's join with geometries doesn't go