Re: pgsql: Re-add item with better description: > * Allow ORDER BY ...
В списке pgsql-committers по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: pgsql: Re-add item with better description: > * Allow ORDER BY ... |
| Дата | |
| Msg-id | 19341.1114442952@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | pgsql: Re-add item with better description: > * Allow ORDER BY ... (momjian@svr1.postgresql.org (Bruce Momjian)) |
| Ответы |
Re: pgsql: Re-add item with better description: > * Allow
|
| Список | pgsql-committers |
momjian@svr1.postgresql.org (Bruce Momjian) writes:
> Re-add item with better description:
>> * Allow ORDER BY ... LIMIT 1 to select high/low value without sort or
>> index using a sequential scan for highest/lowest values
>>
>> Right now, if no index exists, ORDER BY ... LIMIT 1 requires we sort
>> all values to return the high/low value. Instead The idea is to do a
>> sequential scan to find the high/low value, thus avoiding the sort.
That's not much better, as it simply begs the question "why not use
MIN/MAX"?
I think the real point of Oleg's suggestion is a better way to do "top N"
queries. This does not get interesting unless N > 1.
regards, tom lane
В списке pgsql-committers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера