Skip site navigation (1) Skip section navigation (2)

Re: [PATCH] Prevent pg_dump running out of memory

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Martijn van Oosterhout <kleptog(at)svana(dot)org>
Cc: pgsql-patches(at)postgresql(dot)org
Subject: Re: [PATCH] Prevent pg_dump running out of memory
Date: 2001-08-27 20:36:50
Message-ID: 21677.998944610@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-patches
Martijn van Oosterhout <kleptog(at)svana(dot)org> writes:
> This patch replaces the simple SELECT * with a cursor that fetches 1,000 rows
> at a time. The 1,000 was chosen because it was small enough to test but I
> think realisitically 10,000 wouldn't be too much.

Applied.  However, I went the other way: I reduced the 1000 to 100.
I doubt it'll make much difference in performance, and with TOAST
available I can believe people might have multi-megabyte rows.

I also added a cursor CLOSE command, just to be a neatnik.  It's
probably not critical given that the same cursor name is used each
time, but still...

			regards, tom lane

In response to

Responses

pgsql-patches by date

Next:From: Peter EisentrautDate: 2001-08-27 21:02:25
Subject: Re: Makefiles for building with mingw32 on win32
Previous:From: Gerhard HäringDate: 2001-08-27 19:08:09
Subject: Makefiles for building with mingw32 on win32

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group