Re: Date-time extraneous fields with reserved keywords

Joseph Koshakow <koshy44@gmail.com>

From: Joseph Koshakow <koshy44@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Keisuke Kuroda <kuroda.keisuke@nttcom.co.jp>, pgsql-hackers@lists.postgresql.org
Date: 2023-03-04T20:05:08Z
Lists: pgsql-hackers

Attachments

On Sat, Mar 4, 2023 at 2:48 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
>    Right.  So really we ought to move the ValidateDate call as
>    well as the next half-dozen lines about "mer" down into
>    the subsequent "do additional checking" stanza.  It's all
>    only relevant to normal date specs.
>
>    BTW, looking at the set of RESERV tokens in datetktbl[],
>    it looks to me like this change renders the final "default:"
>    case unreachable, so probably we could just make that an error.

Please see the attached patch with these changes.

- Joe Koshakow

Commits

  1. Reject combining "epoch" and "infinity" with other datetime fields.