Re: named generic constraints [feature request]

From: Caleb Cushing <xenoterracide(at)gmail(dot)com>
To: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: named generic constraints [feature request]
Date: 2009-11-24 01:51:13
Message-ID: 81bfc67a0911231751s1a1615b7w6187d046a98e74b0@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> CREATE OR REPLACE FUNCTION emptystr(text)
> RETURNS bool AS $$
>  SELECT $1 <> ''; -- it is SQL not C
> $$ LANGUAGE sql;
>
> CREATE TABLE users(
>  username TEXT CHECK (NOT emptystr(username)),

although I'm not going to continue discussing the request. this code
as the opposite desired effect. it should be

SELECT $1 = ''; -- you have a double negative

--
Caleb Cushing

http://xenoterracide.blogspot.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrew Dunstan 2009-11-24 02:37:25 Re: [PATCH 4/4] Add tests to dblink covering use of COPY TO FUNCTION
Previous Message Greg Smith 2009-11-24 01:46:06 Re: [PATCH 4/4] Add tests to dblink covering use of COPY TO FUNCTION