Re: Comments on Exclusion Constraints and related datatypes

From: Greg Stark <gsstark(at)mit(dot)edu>
To: Simon Riggs <simon(at)2ndquadrant(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Comments on Exclusion Constraints and related datatypes
Date: 2010-03-22 19:46:54
Message-ID: 407d949e1003221246s512602ddo11ba29de551e4cb8@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Mar 22, 2010 at 1:15 PM, Simon Riggs <simon(at)2ndquadrant(dot)com> wrote:
>
> * Circles, Boxes and other geometric datatypes defined "overlaps" to
> include touching shapes. So
>
> * inet datatypes don't have a commutative operator on which a unique
> index can be built. There is no "overlaps" equivalent, which again is a
> shame because that stops them being used with the new feature.

I think our unusual data types are one of the strong points of
Postgres but they're missing a lot of operators and opclasses to make
them really useful.

There's no reason we couldn't have separate overlaps and
overlaps-internally operators just like we have <=,>= and <,>. And it
would be nice to flesh out the network data type more fully, perhaps
merging in as much of ip4r as makes sense.

I remember when I tried to use geometric data types I was stymied by
missing operators. In particular I was surprised that point <in> box
wasn't a gist indexable method. I think that particular case has been
addressed but I think there are many more like it.

--
greg

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2010-03-22 20:02:53 Re: Comments on Exclusion Constraints and related datatypes
Previous Message David Fetter 2010-03-22 19:11:57 Re: Comments on Exclusion Constraints and related datatypes