Re: Ok, why isn't it using *this* index?

Поиск
Список
Период
Сортировка
От Denis A. Doroshenko
Тема Re: Ok, why isn't it using *this* index?
Дата
Msg-id 20010402001346.Y27437@comrade.omnitel.lan
обсуждение исходный текст
Ответ на Re: Ok, why isn't it using *this* index?  (Paul Tomblin <ptomblin@xcski.com>)
Список pgsql-general
On Sun, Apr 01, 2001 at 05:11:46PM -0400, Paul Tomblin wrote:
> Ok, so if I understand you correctly, the fact that about 90% of the
> records have country='USA' and about 9% of the records have
> country='CANADA' means that it's never going to use the index because it
> on average, a query is going to be for USA, and a sequential scan is going
> to be better.
>
> I think I understand now.  If this is correct, then doesn't it make sense
> just to drop that index?  At least until I get a lot more data from other
> countries?

huh, this seems to be ineteresting to know, just because this
"feature" may seriously affect effectivity. by the way, have you tried
to disable sequential scan? that may force pgsql to use an index in
any case, AFAIK.

--
Denis A. Doroshenko  [GPRS/IN/WAP, VAS group engineer] .-.        _|_  |
[Omnitel Ltd., T.Sevcenkos st. 25, Vilnius, Lithuania] | | _ _  _ .| _ |
[Phone: +370 9863486 E-mail: d.doroshenko@omnitel.net] |_|| | || |||(/_|_

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

Предыдущее
От: Joel Burton
Дата:
Сообщение: Re: Can I get the default value for an attribute (field) ?
Следующее
От: Paul Tomblin
Дата:
Сообщение: Re: How do I...