From: | Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com> |
---|---|
To: | Mike Mascari <mascarm(at)mascari(dot)com> |
Cc: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: Any plans on allowing user-defined triggers to be |
Date: | 2004-10-26 14:51:34 |
Message-ID: | 20041026074545.M93012@megazone.bigpanda.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
On Tue, 26 Oct 2004, Mike Mascari wrote:
> Stephan Szabo wrote:
> > On Tue, 26 Oct 2004, Mike Mascari wrote:
> >
> >
> >>I'd like to ensure that the creation of a department also implies the
> >>creation of two to eight projects; no more, no less:
>
> >>Is there no way to achieve the above stated goal in the server? Must I
> >>rely on the application to enforce consistency?
> >
> >
> > Well. It's not exactly meant to be a user facing feature, but check out
> > CREATE CONSTRAINT TRIGGER.
>
> Thanks, Stephan!
>
> I read the disclaimer "It is not intended for general use" but am
> curious as to why it isn't a user-facing feature? Is it a function of
> just exposing a cleaner SQL interface, or is it a function of the
> trigger queue having been written after user-defined triggers, or is
> there some philosophical argument against allowing user-definable
> triggers to be deferred?
It was written basically for dumping/restoring foreign keys in the initial
version of fks and at the time we didn't want to say that we wouldn't
change the syntax to better handle the constraints. We're not using it
for the constraint dumping/restore any longer, but it seems fairly
unlikely to go away at this point unless something else gets put in to
replace it, although the syntax might still change.
From | Date | Subject | |
---|---|---|---|
Next Message | Stephan Szabo | 2004-10-26 14:55:17 | Re: Any plans on allowing user-defined triggers to be |
Previous Message | Tom Lane | 2004-10-26 14:50:16 | Re: Bug: 8.0 beta1 either view optimization or pgdump/pgrestore |