From: | David Rowley <dgrowleyml(at)gmail(dot)com> |
---|---|
To: | Michael Bondarenko <work(dot)michael(dot)2956(at)gmail(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com> |
Cc: | pgsql-bugs(at)lists(dot)postgresql(dot)org |
Subject: | Re: BUG #18348: Inconsistency with EXTRACT([field] from INTERVAL); |
Date: | 2024-02-16 12:44:01 |
Message-ID: | CAApHDvoKGDM=1v1HHGoq6-7mjdqgMYFKk-YSu=iimFz6N6ngDA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs pgsql-hackers |
On Sat, 17 Feb 2024 at 01:27, Michael Bondarenko
<work(dot)michael(dot)2956(at)gmail(dot)com> wrote:
>
> Adding another inconsistency I found in the docs to this thread (https://www.postgresql.org/docs/current/functions-datetime.html#FUNCTIONS-DATETIME-EXTRACT)
>
> The docs say: "source must be a value expression of type timestamp, time, or interval. (Expressions of type date are cast to timestamp and can therefore be used as well.)"
>
> Which implies that the following two results must be the same:
>
> tpch=# select extract(microseconds from date '1924.01.01');
> ERROR: date units "microseconds" not supported
>
> tpch=# select extract(microseconds from (date '1924.01.01')::timestamp);
> extract
> ---------
> 0
It looks like a2da77cdb should have updated the documentation for this.
David
From | Date | Subject | |
---|---|---|---|
Next Message | David Rowley | 2024-02-16 13:02:20 | Re: BUG #18348: Inconsistency with EXTRACT([field] from INTERVAL); |
Previous Message | David Rowley | 2024-02-16 12:32:31 | Re: BUG #18344: Pruning tables partitioned by bool range fails with invalid strategy |
From | Date | Subject | |
---|---|---|---|
Next Message | Mats Kindahl | 2024-02-16 12:45:52 | Re: glibc qsort() vulnerability |
Previous Message | Amit Kapila | 2024-02-16 12:37:16 | Re: pg_upgrade and logical replication |