Re: Optimize join selectivity estimation by not reading MCV stats for unique join attributes

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Optimize join selectivity estimation by not reading MCV stats for unique join attributes
Дата
Msg-id 522124.1668179795@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Optimize join selectivity estimation by not reading MCV stats for unique join attributes  (David Geier <geidav.pg@gmail.com>)
Ответы Re: Optimize join selectivity estimation by not reading MCV stats for unique join attributes
Список pgsql-hackers
David Geier <geidav.pg@gmail.com> writes:
> eqjoinsel() can be optimized by not reading MCV stats if at least one of 
> the two join attributes is unique.

There won't *be* any MCV stats for a column that ANALYZE perceives to
be unique, so I'm not quite sure where the claimed savings comes from.

> With this change we saw some queries improve planning time by more than 
> 2x, especially with larger values for default_statistics_target.

Please provide a concrete example.

            regards, tom lane



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

Предыдущее
От: Pavel Borisov
Дата:
Сообщение: Re: Lockless queue of waiters in LWLock
Следующее
От: Tom Lane
Дата:
Сообщение: Re: A problem about join ordering