Advice on defining indexes

Поиск
Список
Период
Сортировка
От JORGE MALDONADO
Тема Advice on defining indexes
Дата
Msg-id CAAY=A7-0zDKj6diOa7i-jX+biriJ9z-XFjjw-wM6jLzSKQ3Y9A@mail.gmail.com
обсуждение исходный текст
Ответы Re: Advice on defining indexes  (David Johnston <polobo@yahoo.com>)
Список pgsql-sql
I have a table with fields that I guess would be a good idea to set as indexes because users may query it to get results ordered by different criteria. For example:

------------------
Artists Table
------------------
1. art_id
2. art_name
3. art_bday
4. art_sex
5. art_country (foreign key, there is a table of countries)
6. art_type (foreign key, there is a table of types of artists)
7. art_email
8. art_comment
9. art_ bio

"art_id" is the primary key.
Users query the table to get results ordered by fields (2) to (6). Is it wise to define such fields as indexes?

I ask this question because our database has additional tables with the same characteristics and maybe there would be many indexes.

With respect,
Jorge Maldonado

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

Предыдущее
От: Adrian Klaver
Дата:
Сообщение: Re: Unique index VS unique constraint
Следующее
От: David Johnston
Дата:
Сообщение: Re: Advice on defining indexes