Re: way to speed up a SELECT DISTINCT?

Поиск
Список
Период
Сортировка
От Shridhar Daithankar
Тема Re: way to speed up a SELECT DISTINCT?
Дата
Msg-id 3F86914E.2070100@persistent.co.in
обсуждение исходный текст
Ответ на Re: way to speed up a SELECT DISTINCT?  (Seth Ladd <seth@picklematrix.net>)
Список pgsql-performance
Seth Ladd wrote:

>> peter@bernardo:express=# explain select distinct region from region;
>>                                           QUERY PLAN
>> -----------------------------------------------------------------------
>> -----------------------
>>  Unique  (cost=0.00..4326.95 rows=9518 width=14)
>>    ->  Index Scan using regionview_region on region   (cost=0.00..4089.00
>> rows=95183 width=14)
>> (2 rows)
>
>
> Thanks for the tip, I'll give this a shot soon.  I am curious, your
> example above does not use GROUP BY yet you have an INDEX SCAN.  I am
> using a similar query, yet I get a full table scan.  I wonder how they
> are different?

Have you tuned your shared buffers and effective cache correctly?

  Shridhar


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

Предыдущее
От: Seth Ladd
Дата:
Сообщение: Re: way to speed up a SELECT DISTINCT?
Следующее
От: Christopher Kings-Lynne
Дата:
Сообщение: Re: way to speed up a SELECT DISTINCT?