Re: Range Types: empty ranges

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: Range Types: empty ranges
Дата
Msg-id AANLkTinLOEHbTSyZirzmaSoV40ODs=AKP-tzTBmXw6VJ@mail.gmail.com
обсуждение исходный текст
Ответ на Range Types: empty ranges  (Jeff Davis <pgsql@j-davis.com>)
Ответы Re: Range Types: empty ranges  (Jeff Davis <pgsql@j-davis.com>)
Список pgsql-hackers
On Fri, Feb 11, 2011 at 1:11 PM, Jeff Davis <pgsql@j-davis.com> wrote:
> Similarly, "intersection" of ranges is somewhat analogous to
> multiplication of numbers.

I had a feeling that we might be going in this direction.  It strikes
me that this case is a bit like division by zero.  It's kind of a
nuisance that dividing by zero throws an error and we COULD fix that
by making it return NULL or NaN or some new distinguished value DbZ.
But then we'd have to define what happens when you feed DbZ into every
other operation in the system, and similarly here.  If we define two
non-overlapping ranges as intersecting to NULL, or as throwing an
error, then everything else is clear after that.  I'm not sure it's
worth complicating the representation and the definitions of other
operations to cater to this case.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Kevin Grittner"
Дата:
Сообщение: Re: Range Types: empty ranges
Следующее
От: Robert Haas
Дата:
Сообщение: Re: ALTER TYPE 2: skip already-provable no-work rewrites