Re: FETCH FIRST clause WITH TIES option

Поиск
Список
Период
Сортировка
От Surafel Temesgen
Тема Re: FETCH FIRST clause WITH TIES option
Дата
Msg-id CALAY4q-+CKiFkgCL5VSK-9P8i5Z9uoQQh6ZEZLkjzsUT2mySsw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: FETCH FIRST clause WITH TIES option  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Ответы Re: FETCH FIRST clause WITH TIES option  (Michael Paquier <michael@paquier.xyz>)
Список pgsql-hackers


On Tue, Jan 15, 2019 at 2:51 PM Tomas Vondra <tomas.vondra@2ndquadrant.com> wrote:
 
What do you mean by "raw statistic"?

I mean without further calculation to consider other operation 


IMHO the best thing you can do is call estimate_num_groups() and combine
that with the number of input rows. That shall benefit from ndistinct
coefficients when available, etc. I've been thinking that considering
the unreliability of grouping estimates we should use a multiple of the
average size (because there may be much larger groups), but I think
that's quite unprecipled and I'd much rather try without it first.


thank you for clarifying.

The attache patch use your suggestion uptread

regards

Surafel

Вложения

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

Предыдущее
От: Adrien NAYRAT
Дата:
Сообщение: Re: Log a sample of transactions
Следующее
От: Masahiko Sawada
Дата:
Сообщение: Re: Log a sample of transactions