Re: EXPLAIN ... FOR PORTION OF should not evaluate bounds

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: EXPLAIN ... FOR PORTION OF should not evaluate bounds
Date: 2026-09-08 13:44:39
Message-ID: 79c6f8af-64c7-4030-9047-48daf97d60fb@eisentraut.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 04.09.26 06:43, Paul A Jungwirth wrote:
> Here is a fix for findings D3 & D4 & D10 from [0].
>
> The issue is that we evaluate FOR PORTION OF bounds even under
> EXPLAIN. This causes various problems, like failing on `EXPLAIN
> (GENERIC PLAN)`, failing on `FOR PORTION OF (null)`, and calling
> functions for the bounds (beyond selectivity estimation). To fix it,
> we add a guard for EXEC_FLAG_EXPLAIN_ONLY.
>
> [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 Richard Guo 2026-09-08 13:47:21 Re: Assert failure in try_nestloop_path()
Previous Message torikoshia 2026-09-08 13:17:13 Re: RFC: Logging plan of the running query