Re: LIKE search and performance

Поиск
Список
Период
Сортировка
От James Mansion
Тема Re: LIKE search and performance
Дата
Msg-id 4655FB8A.1040707@mansionfamily.plus.com
обсуждение исходный текст
Ответ на Re: LIKE search and performance  (Magnus Hagander <magnus@hagander.net>)
Ответы Re: LIKE search and performance  (Mark Lewis <mark.lewis@mir3.com>)
Список pgsql-performance
> If Sybase is still like SQL Server (or the other way around), it *may*
> end up scanning the index *IFF* the index is a clustered index. If it's
> a normal index, it will do a sequential scan on the table.
>
>
Are you sure its not covered?  Have to check at work - but I'm off next
week so it'll have to wait.

> It's not a win on PostgreSQL, because of our MVCC implementation. We
> need to scan *both* index *and* data pages if we go down that route, in
> which case it's a lot faster to just scan the data pages alone.
>
>
Why do you need to go to all the data pages - doesn't the index
structure contain all the keys so
you prefilter and then check to see if the *matched* items are still in
view?  I'll be first to admit I
know zip about Postgres, but it seems odd - doesn't the index contain
copies of the key values?.

I suspect that I mis-spoke with 'leaf'.  I really just mean 'all index
pages with data', since the scan
does not even need to be in index order, just a good way to get at the
data in a compact way.



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

Предыдущее
От: Magnus Hagander
Дата:
Сообщение: Re: LIKE search and performance
Следующее
От: Mark Lewis
Дата:
Сообщение: Re: LIKE search and performance