Re: order by has no effect in index-choose?

Поиск
Список
Период
Сортировка
От Harald Krake
Тема Re: order by has no effect in index-choose?
Дата
Msg-id atnito$2hlh$1@news.hub.org
обсуждение исходный текст
Список pgsql-admin
Klaus Daum wrote:

> i have:
>
>   create table t (id int, s1 text, s2 text);
>   create index s1 on t using (id, s1);
>   create index s2 on t using (id, s2);
>
> [fill table t, analyse table t]
>
>   select * from t where id=1 order by s1;
>
> -> is using index s2

select * from t where id=1 order by id,s1

will use s1.




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

Предыдущее
От: "Rajesh Kumar Mallah."
Дата:
Сообщение: Is it harmless?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Is it harmless?