Two indexes on same column

Поиск
Список
Период
Сортировка
Искать
От
Vlastimil Krejcir
Тема
Two indexes on same column
Дата
Msg-id
Pine.GSO.4.64.1107201101240.13966@dior.ics.muni.cz
Список
Дерево обсуждения
Two indexes on same column Vlastimil Krejcir <krejcir@ics.muni.cz>
Re: Two indexes on same column Raghavendra <raghavendra.rao@enterprisedb.com>
Re: Two indexes on same column Ernesto Quiñones <ernestoq@gmail.com>
   Hi,

   what index is used (and according to what rules) when there are two (or 
more) different indexes defined on one column? Assume:

CREATE TABLE example (
id SERIAL PRIMARY KEY,
...);
CREATE INDEX example_id_idx ON example USING hash (id);

By default there are btree index created and the hash index is then 
created. So there are two indexes on column "id". Are there described 
somewhere what index is used and when? Does it depend on query analyzer 
and planner?

Thanks

Vlastik

В списке pgsql-general по дате отправления
От: Greg Smith
Дата:
От: Raghavendra
Дата:
Сообщение: Re: Two indexes on same column
FAQ