Re: [PATCH] Possible wrong result from inlining a STRICT SQL function

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Ayush Tiwari <ayushtiwari(dot)slg01(at)gmail(dot)com>
Cc: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [PATCH] Possible wrong result from inlining a STRICT SQL function
Date: 2026-07-28 16:46:43
Message-ID: 4170119.1785257203@sss.pgh.pa.us
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Ayush Tiwari <ayushtiwari(dot)slg01(at)gmail(dot)com> writes:
> It looks like contain_nonstrict_functions() now relies on
> check_functions_in_node() for ScalarArrayOpExpr. That verifies that the
> operator function is strict, but it does not account for whether the
> array can be empty. Before 2f153ddfdd3, this code used
> is_strict_saop() with falseOK = false.

Ugh, yes, clearly brain fade on my part. I think your proposed
test cases are quite excessive, but the code patch seems sound.
Will get it committed.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2026-07-28 17:03:15 Re: [PATCH] SAOP nullability analysis below NOT/BooleanTest
Previous Message Jeff Davis 2026-07-28 16:21:01 Re: [Bug] pg_upgrade could fail for non-superuser subscriptions using foreign servers