Re: Interval - incorrect grammar form - Mailing list pgsql-bugs

From Michael Paquier
Subject Re: Interval - incorrect grammar form
Date
Msg-id CAB7nPqT2gbS2rz7do-LWEKstCbH6WmOaP8wFB3e1nTxUtxttog@mail.gmail.com
Whole thread Raw
In response to Interval - incorrect grammar form  (pinker <pinker@onet.eu>)
Responses Re: Interval - incorrect grammar form
List pgsql-bugs
On Thu, Jul 16, 2015 at 4:56 PM, pinker <pinker@onet.eu> wrote:
> 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"

It behaves like this for ages, and there are some applications that
surely rely on the current behavior, so I am not sure that it is worth
changing now even if that's grammatically incorrect (native
English-speaker wanted here for confirmation).
Regards,
--
Michael

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #13503: json_to_hstore does not works with backslash-quote in json value
Next
From: Tom Lane
Date:
Subject: Re: Interval - incorrect grammar form