Re: [badalex@gmail.com: Re: [BUGS] Problem identifying constraints which should not be inherited] - Mailing list pgsql-patches

From Tom Lane
Subject Re: [badalex@gmail.com: Re: [BUGS] Problem identifying constraints which should not be inherited]
Date
Msg-id 5873.1210168338@sss.pgh.pa.us
Whole thread Raw
In response to Re: [badalex@gmail.com: Re: [BUGS] Problem identifying constraints which should not be inherited]  ("Alex Hunsaker" <badalex@gmail.com>)
List pgsql-patches
"Alex Hunsaker" <badalex@gmail.com> writes:
> Currently this loops through all the constraints for a relation (old
> behavior of MergeAttributesIntoExisting)... Do you think its worth
> adding a non-unique index to speed this up?

No.  If we were to refactor pg_constraint as I mentioned earlier,
then it could have a natural primary key (reloid, constrname)
(replacing the existing nonunique index on reloid) and then a number
of things could be sped up.  But just piling more indexes on a
fundamentally bad design doesn't appeal to me ...

Will review the revised patch today.

            regards, tom lane

pgsql-patches by date:

Previous
From: Stephen Frost
Date:
Subject: Re: column level privileges
Next
From: Simon Riggs
Date:
Subject: [Fwd: Re: [HACKERS] pg_dump additional options for performance]