Re: ALTER TABLE hangs - Mailing list pgsql-admin

From Stephan Szabo
Subject Re: ALTER TABLE hangs
Date
Msg-id 20020429134741.S65313-100000@megazone23.bigpanda.com
Whole thread Raw
In response to ALTER TABLE hangs  (Mike Baker <bakerlmike@yahoo.com>)
Responses Re: ALTER TABLE hangs  (Mike Baker <bakerlmike@yahoo.com>)
List pgsql-admin
On Mon, 29 Apr 2002, Mike Baker wrote:

> Hi.
>
> I am in the process of doing some data migration.  I
> have had no trouble moving my data, but am having
> problems creating a foreign key.
>
> When I run the following command, psql hangs (well,
> not totally sure if it is hung).

It probably isn't hung, but it's going to go through
every row of the table to make sure the constraint holds
successfully which is going to result in 380,000
queries again t_release_component. I haven't had time
recently to do any of the fk stuff I've been meaning to
do, but this is optimizable for most cases, but it hasn't
been done.


pgsql-admin by date:

Previous
From: Mike Baker
Date:
Subject: ALTER TABLE hangs
Next
From: "Mr OCP"
Date:
Subject: Upgrading to 7.2 from 7.1