Steve Lau <stevel...@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 
> for the 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


Reply via email to