From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Erik Rijkers <er(at)xs4all(dot)nl> |
Cc: | Jeff Davis <pgsql(at)j-davis(dot)com>, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: Range Types: << >> -|- ops vs empty range |
Date: | 2011-03-11 13:37:08 |
Message-ID: | 201103111337.p2BDb8011923@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Where are we on this?
---------------------------------------------------------------------------
Erik Rijkers wrote:
> On Wed, February 9, 2011 09:35, Jeff Davis wrote:
> > Updated patch.
> >
>
> The operators << >> and -|- have the following behavior with empty ranges:
>
> testdb=# select '-'::int4range << range(200,300);
> ERROR: empty range
> testdb=# select '-'::int4range >> range(200,300);
> ERROR: empty range
> testdb=# select '-'::int4range -|- range(200,300);
> ERROR: empty range
>
> I'm not sure if that is deliberate behavior, but they seem
> almost bugs to me.
>
> Wouldn't it be better (and more practical) if these would
> return false (or perhaps NULL, for 'unknown') ?
>
> (the same goes for all the other range types, btw.)
>
>
> Erik Rijkers
>
>
>
> --
> Sent via pgsql-hackers mailing list (pgsql-hackers(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-hackers
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ It's impossible for everything to be true. +
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2011-03-11 13:54:37 | Re: pg_terminate_backend and pg_cancel_backend by not administrator user |
Previous Message | Fujii Masao | 2011-03-11 13:29:44 | Re: Replication server timeout patch |