Re: Date-Time dangling unit fix - Mailing list pgsql-hackers

From Joseph Koshakow
Subject Re: Date-Time dangling unit fix
Date
Msg-id CAAvxfHeWKnpZ8J76i8a++ZuwAJVJ94gAi-syf7pNnCd22Jo-Sg@mail.gmail.com
Whole thread Raw
In response to Re: Date-Time dangling unit fix  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Date-Time dangling unit fix  (Joseph Koshakow <koshy44@gmail.com>)
List pgsql-hackers
On Sun, Mar 5, 2023 at 12:54 PM Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> We do accept this:
>
> => select '12:34'::time;
>    time  
> ----------
>  12:34:00
> (1 row)
>
> so that must be going through a different code path, which I didn't
> try to identify yet.

That query will contain a single field of "12:34" with ftype DTK_TIME.
That will call into DecodeTime(), which calls into DecodeTimeCommon(),
where we have:

*tmask = DTK_TIME_M;

- Joe Koshakow

pgsql-hackers by date:

Previous
From: Thomas Munro
Date:
Subject: Re: [PATCH] Add CANONICAL option to xmlserialize
Next
From: Joseph Koshakow
Date:
Subject: Re: Date-Time dangling unit fix