Re: timestamped archive data index searches

Поиск
Список
Период
Сортировка
От Ralph Graulich
Тема Re: timestamped archive data index searches
Дата
Msg-id Pine.LNX.4.21.0207211121080.1804-100000@shauny.shauny.de
обсуждение исходный текст
Ответ на Re: timestamped archive data index searches  ("Stephen Birch" <sgbirch@hotmail.com>)
Список pgsql-general
Hi Stephen,


> SELECT MIN(tstamp) FROM det;
> This used a sequence scan even if I do a SET ENABLE_SEQSCAN to off.
> Shouldn't this also use an index?
[...]

Have a look at the thread I started under "max() not using index". I think
you can do the same trick to work around the min() problem if it's
logical. That'd be:

    SELECT tmstamp FROM det ORDER BY tmstamp ASC LIMIT 1;


Kind regards
... Ralph ...



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

Предыдущее
От: "Stephen Birch"
Дата:
Сообщение: Re: timestamped archive data index searches
Следующее
От: Bruno Wolff III
Дата:
Сообщение: Re: timestamped archive data index searches