From: Peter J. Holzer <hjp-pgsql@hjp.at>
To: pgsql-general@lists.postgresql.org
Subject: Re: creating a subset DB efficiently ?
Date: Sat, 9 Mar 2024 22:34:55 +0100
Message-ID: <20240309213455.i2trc3sc4caxoqel@hjp.at> (raw)
In-Reply-To: <CAEs=6DmuXckUagHG2-mjfXWcjXhU6U7ZqpwB9WxxGdrGKi3DyQ@mail.gmail.com>
References: <CAEs=6DmuXckUagHG2-mjfXWcjXhU6U7ZqpwB9WxxGdrGKi3DyQ@mail.gmail.com>
On 2024-03-08 11:22:17 -0500, David Gauthier wrote:
> Related question...
> The "delete from par_tbl_a where project <> 'a' " is taking forever.
Have you checked whether all the FK columns have an index? Otherwise
checking for references means a full table scan which may take a long
time.
hp
--
_ | Peter J. Holzer | Story must make more sense than reality.
|_|_) | |
| | | hjp@hjp.at | -- Charles Stross, "Creative writing
__/ | http://www.hjp.at/ | challenge!"
Attachments:
signature.asc (application/pgp-signature, 832B) download
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: hjp-pgsql@hjp.at
Subject: Re: creating a subset DB efficiently ?
In-Reply-To: <20240309213455.i2trc3sc4caxoqel@hjp.at>
References: <CAEs=6DmuXckUagHG2-mjfXWcjXhU6U7ZqpwB9WxxGdrGKi3DyQ@mail.gmail.com> <20240309213455.i2trc3sc4caxoqel@hjp.at>
* 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