Interval - incorrect grammar form

Поиск
Список
Период
Сортировка
От pinker
Тема Interval - incorrect grammar form
Дата
Msg-id 1437033362097-5858132.post@n5.nabble.com
обсуждение исходный текст
Ответы Re: Interval - incorrect grammar form  (Michael Paquier <michael.paquier@gmail.com>)
Список pgsql-bugs
Hi,
I've noticed that interval is shown incorrectly (in plural form) when date
is negative:

select age(timestamp '2015-09-01',timestamp '2017-10-02');
gives:
"-2 years -1 *mons* -1 days"

This mistake isn't present when date is positive
select age(now(),'2015-06-07');

"1 *mon* 9 days 11:53:37.567851"

It applies to versions:
"PostgreSQL 9.4.1 on x86_64-unknown-linux-gnu, compiled by gcc (GCC) 4.1.2
20080704 (Red Hat 4.1.2-55), 64-bit"
and
"PostgreSQL 8.4.17 on i486-pc-linux-gnu, compiled by GCC gcc-4.4.real
(Debian 4.4.5-8) 4.4.5, 32-bit"



--
View this message in context: http://postgresql.nabble.com/Interval-incorrect-grammar-form-tp5858132.html
Sent from the PostgreSQL - bugs mailing list archive at Nabble.com.

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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: BUG #13502: parser misconstrues table alias
Следующее
От: kolmyk@hotmail.com
Дата:
Сообщение: BUG #13503: json_to_hstore does not works with backslash-quote in json value