deferrable check, trigger - Mailing list pgsql-hackers

From Horváth Sándor
Subject deferrable check, trigger
Date
Msg-id 443127BF.40705@ritek.hu
Whole thread Raw
List pgsql-hackers
Hi!

I has needed deferrable constraint CHECK, but i'm sorry, because it has 
not implemented.
I has studied the postgresql source code, and i think there are three 
possibilities in implementation:

1. implementing deferrable check. It is not easy (there is no deferred 
constraint manager), but it is corresponds to current sql syntax of 
postgresql.
2. allow deferrable triggers for all type of triggers (or at least for 
after trigger). I thing it is easier to do, because it exists, but 
limited for a special kind of trigger. The problem of this solution is, 
that is not corresponds to current sql syntax.
I prefer this, because of the deferrable trigger is very useful 
(checking of deferrable unique constraint, etc...)
3. implement deferrable check at sql level, but deferred after trigger 
at inner level. (like foreign key implementation)

What is about this?

Horváth Sándor


pgsql-hackers by date:

Previous
From: "Martin Scholes"
Date:
Subject: Re: WAL Bypass for indexes
Next
From: Tom Lane
Date:
Subject: Re: WAL Bypass for indexes