Re: Implement missing join selectivity estimation for range types - Mailing list pgsql-hackers

From Bryan Green
Subject Re: Implement missing join selectivity estimation for range types
Date
Msg-id 6929b807-32e9-4e80-b3d3-1f7823880d60@gmail.com
Whole thread
In response to Re: Implement missing join selectivity estimation for range types  (Haibo Yan <tristan.yim@gmail.com>)
Responses Re: Implement missing join selectivity estimation for range types
List pgsql-hackers
On 4/24/2026 1:44 PM, Haibo Yan wrote:
> On Thu, Apr 23, 2026 at 5:32 AM SCHOEMANS Maxime <maxime.schoemans@ulb.be>
> wrote:
> 
>> Hi Haibo,
>>
>> Thanks for creating the CommitFest entry. Could you add Diogo Repas,
>> Zhicheng Luo, and Mahmoud Sakr as authors as well? They wrote the
>> original patch and the underlying algorithm. The earlier CF entry is
>> at https://commitfest.postgresql.org/patch/3821/ for reference.
>>
>> Of course — I’ve added Diogo Repas, Zhicheng Luo, and Mahmoud Sakr as
> authors as we
> 
>> Regards,
>> Maxime
>>
> Thanks for the reference.
> 
> Best regards,
> Haibo


One thing that might be a problem is that rangejoinsel and
multirangejoinsel (0002) look like they use the bounds histogram without
the statistic_proc_security_check() that calc_hist_selectivity does just
above. If I follow it correctly, that runs the cmp/subdiff over another
role's histogram at plan time, before the permission check, which I
believe is what CVE-2017-7484 guarded against.


-- 
Bryan Green
EDB: https://www.enterprisedb.com



pgsql-hackers by date:

Previous
From: Alexander Korotkov
Date:
Subject: Re: Reject WAIT FOR earlier in transaction-snapshot mode
Next
From: Bernd Reiß
Date:
Subject: Re: [Patch] New pg_stat_tablespace view