Re: [GENERAL] 7.4Beta - Mailing list pgsql-hackers

From Stephan Szabo
Subject Re: [GENERAL] 7.4Beta
Date
Msg-id 20030814233926.D8240-100000@megazone.bigpanda.com
Whole thread Raw
List pgsql-hackers
On Fri, 15 Aug 2003, Christopher Kings-Lynne wrote:

> > We've talked about stuff like that in the past, but we seem to generally
> > get stuck about how to specify it.  If we add it to the alter table add as
> > an option then we're generating statements that are almost like a standard
> > sql statement, but not quite, and some people didn't like that. A set
> > option that only affected ALTER TABLE ADD CONSTRAINT wouldn't be too bad,
> > but I'd be worried about making it apply to the normal checks as well
> > (which I believe was suggested last time this came up).  In any case,
> > making the full checks faster for when you really do care isn't a bad
> > plan. :)
>
> Or, this:
>
> 1. Add the FK to the table BEFORE COPYing data
> 2. Use the old update blah set reltriggers = 0 trick
> 3. restore the data
> 4. Undo step 2

The problem with that is that I think the reltriggers=0 trick only works
if you're superuser, I thought that's why the trigger disabling became
optional.  A set that affected only atac would probably be reasonable in
the dump (and presumably easy to do).  It'd also carry over to future
cases where we separate some check constraints (for examples ones
that refer directly or indirectly to the same table in a subselect).



pgsql-hackers by date:

Previous
From: "Christopher Kings-Lynne"
Date:
Subject: Re: [GENERAL] 7.4Beta
Next
From: "Christopher Kings-Lynne"
Date:
Subject: Re: [GENERAL] 7.4Beta