Re: EXCLUDE constraint with not equals

From: Kai Groner <kai(at)gronr(dot)com>
To: emre(at)hasegeli(dot)com
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: EXCLUDE constraint with not equals
Date: 2015-03-03 17:34:55
Message-ID: CALiRuxnj+_H+BEauMKfn8xN0QXygLu4f0XgHLh-YNkqp7q55ww@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, Mar 3, 2015 at 11:15 AM, Kai Groner <kai(at)gronr(dot)com> wrote:

> I found it necessary to add the gist_text_ops opclass for the inequality:
>
> CREATE TABLE person (
> id INTEGER PRIMARY KEY,
> "user" TEXT,
> email TEXT NOT NULL,
> EXCLUDE USING gist (email WITH =, "user" gist_text_ops WITH <>)
> WHERE ("user" IS NOT NULL));
>
> Is that expected?
>

Never mind. I was creating the extension on the wrong database and
misunderstood the error.

Kai

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Francisco Olarte 2015-03-03 18:00:08 Re:
Previous Message Greg Sabino Mullane 2015-03-03 17:11:17 Re: Performance on DISABLE TRIGGER (resend)