Re: Precedence of a TRIGGER vs. a CHECK on a column

From: Stephan Szabo <sszabo(at)megazone(dot)bigpanda(dot)com>
To: ezra epstein <ee_newsgroup_post(at)prajnait(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Precedence of a TRIGGER vs. a CHECK on a column
Date: 2004-01-19 19:36:46
Message-ID: 20040119113338.B46565@megazone.bigpanda.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


On Sun, 11 Jan 2004, ezra epstein wrote:
> So it seems that the CHECK definied for the non_empty_name domain is being
> applied before the trigger is executed. Yet, it seems that NON NULL
> constraints are applied after triggers get called.

I think it's that your domain constraint is being applied before the
trigger is executed and that the table constraints are being applied
after given that I get the same behavior with a domain constraint of not
null. This makes sense (although I haven't checking the spec wording)
since the value is being coerced into the domain in order to be put into
the row that's being passed to the trigger (thus triggering the domain
constraints).

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Joshua D. Drake 2004-01-19 19:42:15 Re: New PostgreSQL search resource
Previous Message Jussi Mikkola 2004-01-19 19:33:59 Re: New PostgreSQL search resource