Re: Reducing some DDL Locks to ShareLock - Mailing list pgsql-hackers

From Simon Riggs
Subject Re: Reducing some DDL Locks to ShareLock
Date
Msg-id 1223388713.4747.180.camel@ebony.2ndQuadrant
Whole thread Raw
In response to Re: Reducing some DDL Locks to ShareLock  ("Robert Haas" <robertmhaas@gmail.com>)
Responses Re: Reducing some DDL Locks to ShareLock
Re: Reducing some DDL Locks to ShareLock
List pgsql-hackers
On Tue, 2008-10-07 at 10:05 -0400, Robert Haas wrote:
> > 3. The patch introduces a slight weirdness: if you create two FKs on the
> > same column at the same time you end up with two constraints with
> > identical names. Drop constraint then removes them both, though in other
> > respects they are both valid, just not uniquely. CREATE INDEX avoids
> > this by way of the unique index on relname. The equivalent index on
> > pg_constraint is not unique, though *cannot* be made unique without
> > breaking some corner cases of table inheritance.
> 
> Urk... this seems pretty undesirable.

OK, but please say what behaviour you would like in its place. 

Or are you saying you dislike this so much that you would prefer not to
be able to run ALTER TABLE concurrently?

Also, how often do you think this will be a problem? This only happens
when you have two FKs on the exact same column set. That happens seldom,
if ever, AFAICS.

-- Simon Riggs           www.2ndQuadrant.comPostgreSQL Training, Services and Support



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [PATCHES] Infrastructure changes for recovery
Next
From: Simon Riggs
Date:
Subject: Re: [PATCHES] Infrastructure changes for recovery