| От | Tom Lane |
|---|---|
| Тема | Re: Index of expression over table row or column |
| Дата | |
| Msg-id | 4169601.1729048988@sss.pgh.pa.us обсуждение |
| Ответ на | Index of expression over table row or column (Steve Lau <stevelauc@outlook.com>) |
| Ответы |
Re: Index of expression over table row or column
|
| Список | pgsql-docs |
Steve Lau <stevelauc@outlook.com> writes:
> I am reading this documentation[1], and it has a sentence that I don’t quite understand: "The index columns (key
values)can be either simple columns of the underlying table or expressions over the table rows.”, I am thinking that
forthe index of expressions, aren’t those expressions over table column? e.g., “CREATE INDEX idx_lower_last_name ON
users(LOWER(last_name))”,“last_name" is a column rather than a row.
Consider
CREATE INDEX idx_lower_name ON users(LOWER(last_name || ' ' || first_name));
regards, tom lane
В списке pgsql-docs по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера