Don Baccus <dhogaza(at)pacifier(dot)com> writes:
> According to Date, a check contraint should fail if the expression
> evaluates to false.
And SQL92 says:
A table check constraint is satisfied if and only if the specified
<search condition> is not false for any row of a table.
^^^^^^^^^
so they agree: a constraint that yields NULL should be considered
to pass. A tad nonintuitive, but who am I to argue...
I have fixed several bugs recently having to do with incorrect
evaluation of three-state boolean logic. I'll take care of this one.
regards, tom lane