Re: limit order by performance issue

Поиск
Список
Период
Сортировка
От Marti Raudsepp
Тема Re: limit order by performance issue
Дата
Msg-id CABRT9RAKSdwRUE6PrCg6XV=xXi8U2Nyx9Q0YK_ob=yQ2DXuGRw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: limit order by performance issue  (Karl Denninger <karl@denninger.net>)
Список pgsql-performance
On Tue, Oct 16, 2012 at 10:47 PM, Karl Denninger <karl@denninger.net> wrote:
> Put an index on time_stamp (I assume there is one on id_signal already)

Well the optimal index for this particular query would include both columns:
(id_signal, time_stamp) -- in this order.

Additionally, if you want to take advantage of the index-only scans
feature, add the SELECTed column too:
(id_signal, time_stamp, var_value)

Regards,
Marti


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

Предыдущее
От: Merlin Moncure
Дата:
Сообщение: Re: LIKE op with B-Tree Index?
Следующее
От: Chris Ruprecht
Дата:
Сообщение: Have: Seq Scan - Want: Index Scan - what am I doing wrong?