Re: FOR PORTION OF bounds not coerced in PREPARE

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: Paul A Jungwirth <pj(at)illuminatedcomputing(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: FOR PORTION OF bounds not coerced in PREPARE
Date: 2026-09-08 08:48:29
Message-ID: 7d27a411-cd43-4bc1-a9c3-ec891f8dd1c7@eisentraut.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 04.09.26 06:35, Paul A Jungwirth wrote:
> Here is a fix for findings D2 & D12 from [0].
>
> The issue is FOR PORTION OF bounds are not coerced, so PREPARE
> requires casting them and a NULL deparses as ::unknown not
> ::date/::timestamp/etc. We actually do coerce these bounds, since we
> have to build a range constructor, but we don't put those into the
> ForPortionOfExpr struct. This commit fixes that.
>
> [0] https://www.postgresql.org/message-id/CA%2BrenyV6QLOJYmLo3gbsg1Y%2BCrho8NqME1jJXgPbO_NgxfBaKQ%40mail.gmail.com

committed

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message xliu19163 2026-09-08 08:50:17 Re: Batching in executor
Previous Message Jinqing Kuang 2026-09-08 08:17:25 Re: [Patch] Implement TODOs for index operator strategy number validation