PostgreSQL 7.0.2 Date Miscalculation

Поиск
Список
Период
Сортировка
От pgsql-bugs@postgresql.org
Тема PostgreSQL 7.0.2 Date Miscalculation
Дата
Msg-id 200104022352.f32Nqgd45931@hub.org
обсуждение исходный текст
Ответы Re: PostgreSQL 7.0.2 Date Miscalculation  (Robert Hentosh <hentosh@io.com>)
Список pgsql-bugs
Jay Guerette (JayGuerette@pobox.com) reports a bug with a severity of 2
The lower the number the more severe it is.

Short Description
PostgreSQL 7.0.2 Date Miscalculation

Long Description
PostgreSQL 7.0.2

The RELTIME function is miscalculating dates.
(all my graphs were wrong today!)

Sample Code
The query:

SELECT STAMP FROM SYSLOG WHERE DATE(STAMP)=DATE(TIMESTAMP('TODAY'-'1 WEEK'::RELTIME)) LIMIT 1;

Produces:

         stamp
------------------------
 2001-03-25 02:53:52-05
(1 row)

When the date is:

Mon Apr  2 19:45:40 EDT 2001

And the result SHOULD be:

         stamp
------------------------
 2001-03-26 02:53:52-05

I also have NO idea what this means:

SELECT DATE(CURRENT_DATE - ('1 WEEK'::RELTIME));
    date
------------
 0345-05-14
(1 row)


No file was uploaded with this report

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

Предыдущее
От: "V. M."
Дата:
Сообщение: compile error for DBD-Pg-0.95 + Cannot insert a duplicate key
Следующее
От: Philip Warner
Дата:
Сообщение: Re: Table constraint ordering disrupted by pg_dump