Re: BUG #14446: make_date with negative year

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: BUG #14446: make_date with negative year
Дата
Msg-id 20161205183837.dcs5y3sfoiwgv6b3@alvherre.pgsql
обсуждение исходный текст
Ответ на Re: BUG #14446: make_date with negative year  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: BUG #14446: make_date with negative year  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-bugs
Pavel Stehule wrote:
> 2016-12-04 14:40 GMT+01:00 Alvaro Herrera <alvherre@2ndquadrant.com>:

> > abelisto@gmail.com wrote:
> > >
> > > with t(x) as (values('1111-11-11 BC'::date)) select
> > make_date(extract(year
> > > from x)::int, extract(month from x)::int, extract(day from x)::int) from
> > > t;
> > > ERROR:  date field value out of range: -1111-11-11

So make_date was introduced in 9.4 by commit f901bb50e; this report is
based on 9.5.  Do we want to backpatch this change?  Since the fix only
changes behavior that currently errors out anyway, we would not be
changing anything that people are relying on.  I lean towards
backpatching all the way back to 9.4 myself.

--
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: BUG #14449: inconsistency in behaviour of json/jsonb returning functions for sql NULL and json NULL values
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: BUG #14446: make_date with negative year