From: ktm@rice.edu <ktm@rice.edu>
To: Reuven M. Lerner <reuven@lerner.co.il>
Cc: Andrew Dunstan <andrew@dunslane.net>
Cc: Marcin Mańk <marcin.mank@gmail.com>
Cc: pgsql-performance@postgresql.org
Subject: Re: Very long deletion time on a 200 GB database
Date: Thu, 23 Feb 2012 09:28:37 -0600
Message-ID: <20120223152837.GV21114@aart.rice.edu> (raw)
In-Reply-To: <4F465A7A.4000905@lerner.co.il>
References: <4F45FB55.1020600@lerner.co.il>
<CAK61fk6bSQtmDUzm2rNv33kN4Oar_dYZ-yFEa9zR_zLL8L9esQ@mail.gmail.com>
<4F464C49.4050503@dunslane.net>
<4F465A7A.4000905@lerner.co.il>
On Thu, Feb 23, 2012 at 05:25:46PM +0200, Reuven M. Lerner wrote:
> >
> >What is the distribution of end_dates? It might be worth running this in
> >several steps, deleting records older than, say, 90 days, 60 days, 30 days.
>
> I've suggested something similar, but was told that we have limited
> time to execute the DELETE, and that doing it in stages might not be
> possible.
>
> Reuven
>
In cases like this, I have often found that doing the delete in smaller
pieces goes faster, sometimes much faster, than the bigger delete.
Regards,
Ken
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: ktm@rice.edu, reuven@lerner.co.il, andrew@dunslane.net, marcin.mank@gmail.com
Subject: Re: Very long deletion time on a 200 GB database
In-Reply-To: <20120223152837.GV21114@aart.rice.edu>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox