Re: Date-Time dangling unit fix

From: Joseph Koshakow <koshy44(at)gmail(dot)com>
To: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Date-Time dangling unit fix
Date: 2022-12-12 15:55:36
Message-ID: CAAvxfHc8xy42wX8Xk7RTLee_O16ui4RfT7vkjfnN+ERgpaHV+g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I just found another class of this bug that the submitted patch does
not fix. If the units are at the beginning of the string, then they are
also ignored. For example, `date 'm d y2020m11d3'` is also valid. I
think the fix here is to check and make sure that ptype is 0 before
reassigning the value to a non-zero number. I'll send an updated patch
with this tonight.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Masahiko Sawada 2022-12-12 16:04:40 Re: [PoC] Improve dead tuple storage for lazy vacuum
Previous Message Robert Haas 2022-12-12 15:40:38 Re: sendFileWithContent() does not advance the source pointer