Re: [PATCH] Fix hashed ScalarArrayOp semantics for NULL LHS with non-strict comparators

From: cca5507 <cca5507(at)qq(dot)com>
To: Chengpeng Yan <chengpeng_yan(at)outlook(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Cc: David Rowley <dgrowleyml(at)gmail(dot)com>
Subject: Re: [PATCH] Fix hashed ScalarArrayOp semantics for NULL LHS with non-strict comparators
Date: 2026-04-17 12:45:57
Message-ID: tencent_75ACCC12DECD8182DD4AA84A617D2D48CA06@qq.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Chengpeng,

Thanks for your report. After reading the code, I find that there is still
an issue even if the LHS is not null and the comparator is strict (make
myinteq always return null, see the attached sql for details).

The main reason is that we did not consider whether the comparator's
return value is null during looking up the hash. Not sure whether this
is a big problem.

--
Regards,
ChangAo Chen

Attachment Content-Type Size
repro.sql application/octet-stream 1.3 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Previous Message Andrew Dunstan 2026-04-17 12:40:41 Re: Reject invalid databases in pg_get_database_ddl()