Re: statistics horribly broken for row-wise comparison

Поиск
Список
Период
Сортировка
От Greg Stark
Тема Re: statistics horribly broken for row-wise comparison
Дата
Msg-id 4136ffa0903030004k573c6156i57890320b3745006@mail.gmail.com
обсуждение исходный текст
Ответ на Re: statistics horribly broken for row-wise comparison  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Tue, Mar 3, 2009 at 3:33 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>
> Because it would be the wrong answer, except in the uncommon case where
> the field values are completely independent (at least, I would expect
> that to be uncommon when people have multicolumn indexes on them).


Actually I think it's *more* likely to be true for multicolumn
indexes. If the two columns were correlated then you wouldn't need the
multicolumn index since you could just use one of the columns alone.
The case where people create multicolumn indexes btree indexes is
usually when they have a "major"-"minor" relationship between the two
columns so for each value of the major key there is a whole range of
minor keys.

Sure multi-column statistics would be nice though.

-- 
greg


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

Предыдущее
От: Heikki Linnakangas
Дата:
Сообщение: Re: Why do we keep UnusedLock1 in LWLockId?
Следующее
От: Simon Riggs
Дата:
Сообщение: Re: Hot standby, running xacts, subtransactions