Re: Using SUBSELECT in CHECK expressions

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Michael Glaesemann <grzm(at)myrealbox(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Using SUBSELECT in CHECK expressions
Date: 2003-11-05 18:12:04
Message-ID: 3555.1068055924@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Michael Glaesemann <grzm(at)myrealbox(dot)com> writes:
> On Thursday, November 6, 2003, at 02:38 AM, Tom Lane wrote:
>> IIRC we check that it is labeled IMMUTABLE.

> Thanks for the clarification. Is this in the documentation somewhere?

[digs...] No, because my recollection is wrong: there's no such check.

regression=# create function foo() returns bool as 'select true' language sql;
CREATE FUNCTION
regression=# create table foo (f1 int check (foo()));
CREATE TABLE

Possibly there should be such a restriction, but there isn't today...

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Michael Glaesemann 2003-11-05 18:25:01 Re: Using SUBSELECT in CHECK expressions
Previous Message Oliver Siegmar 2003-11-05 18:08:02 7.4 is great!