Re: [PATCH] Never convert n_distinct < 2 values to a ratio when computing stats
В списке pgsql-hackers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: [PATCH] Never convert n_distinct < 2 values to a ratio when computing stats |
| Дата | |
| Msg-id | 15920.1332691162@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: [PATCH] Never convert n_distinct < 2 values to a ratio when computing stats (Robert Haas <robertmhaas@gmail.com>) |
| Список | pgsql-hackers |
Robert Haas <robertmhaas@gmail.com> writes:
> The bit about maybe not getting both t and f as MCVs on a Boolean does
> seem a little worrying, but I'm not sure whether it actually affects
> query planning in a materially negative way. Can you demonstrate a
> case where it matters?
If we were trying to force that to happen it would be wrong anyway.
Consider a column that contains *only* "t", or at least has so few
"f"'s that "f" appears never or only once in the selected sample.
(IIRC there is a clamp that prevents selecting anything as an MCV
unless it appears at least twice in the sample.)
Like Robert, I'm not convinced whether or not this is a reasonable
change, but arguing for it on the basis of boolean columns doesn't
seem very sound.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера