Re: Hash-based MCV matching for large IN-lists

Поиск
Список
Период
Сортировка
От Ilia Evdokimov
Тема Re: Hash-based MCV matching for large IN-lists
Дата
Msg-id 8ee9d903-bb13-434c-8145-b3769bf2b3cb@tantorlabs.com
обсуждение исходный текст
Ответ на Re: Hash-based MCV matching for large IN-lists  (Chengpeng Yan <chengpeng_yan@Outlook.com>)
Ответы Re: Hash-based MCV matching for large IN-lists
Список pgsql-hackers

Hi Chengpeng,

Thanks for your review!


On 28.01.2026 16:08, Chengpeng Yan wrote:
* Treat NULL array elements as zero selectivity for ALL:

Agreed. For ALL/AND semantics the function now returns selectivity = 0.0 as soon as a NULL element is encountered.


* Fix cross-type equality argument order in `mcvs_in_equal`:

Agreed. Added 'op_is_reserved' flag MCVInHashContext, same as in MCVHashContext.


* Include non-MCV IN-list constants in non-disjoint selectivity:

This is not applicable to v3.


* Avoid double-negating inequality estimates for non-Const elements:

Agreed. var_eq_non_const() is now always with negate = false, not to call negation twice.


Attached v4 patch with above fixes.

-- 
Best regards,
Ilia Evdokimov,
Tantor Labs LLC,
https://tantorlabs.com/

Вложения

В списке pgsql-hackers по дате отправления: