Re: constraint -- one or the other column not null - Mailing list pgsql-general

From Martijn van Oosterhout
Subject Re: constraint -- one or the other column not null
Date
Msg-id 20060906091239.GA11415@svana.org
Whole thread Raw
In response to Re: constraint -- one or the other column not null  (Ivan Sergio Borgonovo <mail@webthatworks.it>)
List pgsql-general
On Wed, Sep 06, 2006 at 09:59:03AM +0200, Ivan Sergio Borgonovo wrote:
> You can write a xor function. At least in 7.4, that I'm currently using, there is no xor operator.

Ah, but there's is, but it's in disguise:

test=# select true <> true, true <> false, false <> true, false <> false;
 ?column? | ?column? | ?column? | ?column?
----------+----------+----------+----------
 f        | t        | t        | f
(1 row)

Hope this helps,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Attachment

pgsql-general by date:

Previous
From: Alban Hertroys
Date:
Subject: Re: Date using Int8
Next
From: Sim Zacks
Date:
Subject: NT4 client problem