Re: Why overlaps is not working

Поиск
Список
Период
Сортировка
От Andrus
Тема Re: Why overlaps is not working
Дата
Msg-id 031601c70718$ae4f2360$2300b3a8@Andrus
обсуждение исходный текст
Ответ на Re: Why overlaps is not working  (Richard Broersma Jr <rabroersma@yahoo.com>)
Ответы Re: Why overlaps is not working  (Alban Hertroys <alban@magproductions.nl>)
Список pgsql-general
> I thought the suggested solution was to use infinity, hence the
> requirement to cast to timestamps.
> That'd mean something along the lines of:
>
>  where  (a::timestamp, coalesce(b, 'infinity')::timestamp) overlaps
>  (c::timestamp, coalesce(d, 'infinity')::timestamp)

select   (date'20060101'::timestamp, coalesce(date'20060102'::timestamp, 'infinity')) overlaps
  (date'20060102', coalesce(date'20060103'::timestamp, 'infinity'))

returns false but since date'20060102' is overlapping it must return true.
So it seems that it is not possible to use timestamps and infinity.

Andrus.

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

Предыдущее
От: "Rodrigo Sakai"
Дата:
Сообщение: Inserting data in composite types
Следующее
От: Alban Hertroys
Дата:
Сообщение: Re: Why overlaps is not working