Re: Selectivity of "=" (Re: [HACKERS] Index not used on simple se lect)
| От | Hannu Krosing |
|---|---|
| Тема | Re: Selectivity of "=" (Re: [HACKERS] Index not used on simple se lect) |
| Дата | |
| Msg-id | 379FE9D5.430BB918@trust.ee обсуждение исходный текст |
| Ответ на | Re: Selectivity of "=" (Re: [HACKERS] Index not used on simple se lect) (Tom Lane <tgl@sss.pgh.pa.us>) |
| Список | pgsql-hackers |
Tom Lane wrote: > > (2) The statistics that we have available are stats about a column. > Not stats about a column given the predicate of some index. So there's > no gain in our statistical knowledge either. If we added just count of NULLs we would cover for the NOT NULL case > Partial indexes might be a component of a solution, but they are > very far from being a solution all by themselves. > > regards, tom lane > > PS: a quick glance at gram.y shows that we don't actually accept > partial-index predicates in CREATE INDEX, so Andreas was right that > the feature got ripped out at some point. I have no idea how much > work might be required to re-enable it... but I'll bet it's not > trivial. That's why I suggested getting just the simplest case (NOT NULL) working first. The more general approach would of course be to gather stats by index. -------------- Hannu
В списке pgsql-hackers по дате отправления: