From: | Simon Riggs <simon(at)2ndquadrant(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [PATCHES] Inherited Constraints |
Date: | 2005-12-08 22:47:08 |
Message-ID: | 1134082028.2906.1141.camel@localhost.localdomain |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-patches |
On Thu, 2005-12-08 at 11:10 +0000, Simon Riggs wrote:
> On Wed, 2005-12-07 at 21:24 +0000, Simon Riggs wrote:
> > Following patch implements record of whether a constraint is inherited
> > or not, and prevents dropping of inherited constraints.
>
> Patch posted to -patches list.
>
> > What it doesn't do:
> > It doesn't yet prevent dropping the parent constraint, which is wrong,
> > clearly, but what to do about it?
> > 1. make dropping a constraint drop all constraints dependent upon it
> > (without any explicit cascade)
> > 2. add a new clause to ALTER TABLE .... DROP CONSTRAINT .... CASCADE
> >
> > I prefer (1), since it is SQL Standard compliant, easier to remember and
> > automatic de-inheritance is the natural opposite of the automatic
> > inheritance process.
>
> Comments, please -hackers?
Late night hacking again....
ALTER TABLE .... DROP CONSTRAINT .... CASCADE
does of course already exist, so the following should cause dependency
violation ERRORs:
- omitting the CASCADE when attempting to delete parent constraint
- attempting to drop the child constraint
Best Regards, Simon Riggs
From | Date | Subject | |
---|---|---|---|
Next Message | Gregory Maxwell | 2005-12-08 22:54:35 | Re: Upcoming PG re-releases |
Previous Message | Bruce Momjian | 2005-12-08 22:44:34 | Re: Upcoming PG re-releases |
From | Date | Subject | |
---|---|---|---|
Next Message | Trent Shipley | 2005-12-09 01:29:01 | Re: [PATCHES] Inherited Constraints |
Previous Message | Bruce Momjian | 2005-12-08 21:37:09 | Re: AIX FAQ update |