Re: Bug fix for missing years in make_date()

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: David Fetter <david(at)fetter(dot)org>
Cc: Adam Brightwell <adam(dot)brightwell(at)crunchydatasolutions(dot)com>, Jim Nasby <Jim(dot)Nasby(at)bluetreble(dot)com>, PG Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Bug fix for missing years in make_date()
Date: 2015-03-31 16:58:27
Message-ID: 20648.1427821107@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

David Fetter <david(at)fetter(dot)org> writes:
> On Tue, Mar 31, 2015 at 10:34:45AM -0400, Adam Brightwell wrote:
>> Previously, zero was rejected, what does it do now? I'm sure it represents
>> 0 AD/CE, however, is that important enough to note given that it was not
>> allowed previously?

> Now, it's supposed to take 0 as 1 BCE, -1 as 2 BCE, etc. There should
> probably be tests for that.

Surely that is *not* what we want? I'd expect any user-facing date
function to reject zero and take -1 as 1 BC, etc. The behavior you
describe is an internal convention, not something we want to expose
to users.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Abhijit Menon-Sen 2015-03-31 17:13:49 Re: a fast bloat measurement tool (was Re: Measuring relation free space)
Previous Message Jacobo Vazquez 2015-03-31 16:40:40 Fwd: SSPI authentication ASC_REQ_REPLAY_DETECT flag