Re: Estimating costs (was Functional Indices)

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Estimating costs (was Functional Indices)
Дата
Msg-id 15848.990638561@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Estimating costs (was Functional Indices)  (Martijn van Oosterhout <kleptog@svana.org>)
Ответы Re: Estimating costs (was Functional Indices)  (Martijn van Oosterhout <kleptog@svana.org>)
Список pgsql-general
Martijn van Oosterhout <kleptog@svana.org> writes:
> I was thinking "average runlength". If this were 10 for example, when it
> came to calculating the cost of the index scan, it would divide the
> per-tuple cost by 10.

> You can go the simple calculation method which would count the number of
> times the value in a column was different than the previous value, then
> divide that into the total number of tuples. That's not difficult to
> implement.

Unfortunately, it is difficult to implement, in fact impossible, given
the new sampling-based implementation of ANALYZE.  You could only
discover that runs of identical keys exist if you were willing to
examine every row, not just a statistical sample.

Since this seems a rather specialized situation, I'm not eager to pay
that high a price to recognize it ...

            regards, tom lane

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Re: ZeroFill(.../pg_xlog/xlogtemp.20148) failed: No such file or directory
Следующее
От: Chris Jones
Дата:
Сообщение: Re: Re: ZeroFill(.../pg_xlog/xlogtemp.20148) failed: No such file or directory