Allow negative years in make_date to represent BC years

Alvaro Herrera <alvherre@alvh.no-ip.org>

Commit: 30bcebbdcf23eb8b78e553c4b3b5eb847410ef19
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
Date: 2017-01-19T12:45:38Z
Releases: 10.0
Allow negative years in make_date to represent BC years

There doesn't seem to be any reason not to allow negative years to be
interpreted as BC, so do that.

The documentation is pretty vague on the details of this function, so
nothing needs to change there.

Reported-by: Andy Abelisto, in bug #14446

Files

PathChange+/−
src/backend/utils/adt/date.c modified +9 −5
src/test/regress/expected/date.out modified +6 −2
src/test/regress/sql/date.sql modified +1 −1