Re: Check constraints on non-immutable keys

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Check constraints on non-immutable keys
Date: 2010-06-30 22:27:03
Message-ID: 1277936823.27966.41.camel@vanquo.pezone.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On ons, 2010-06-30 at 10:38 -0400, Tom Lane wrote:
> Magnus Hagander <magnus(at)hagander(dot)net> writes:
> > Shouldn't we disallow anything that's not IMMUTABLE in a check constraint?
>
> I think you'd get too many howls of pain ... also, such a restriction is
> likely contrary to SQL spec.

<kibo>
"The <search condition> shall simply contain a <boolean value
expression> that is retrospectively deterministic."

This is then defined in a rather complex manner that ends up disallowing
col > now() but allowing col < now().
</kibo>

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2010-06-30 22:29:26 Re: LLVM / clang
Previous Message Daniel Farina 2010-06-30 22:22:09 Re: Error with GIT Repository