ColumnIndexOptions interface
The clauses of the CREATE INDEX statement that a ColumnIndex declaration turns into.
Signature:
export interface ColumnIndexOptions
Remarks
Every field is optional in practice — both decorators take a Partial of this, and an empty object declares a plain btree index on the column. The names follow Postgres's own CREATE INDEX syntax, and the values of the raw-SQL fields are emitted as written.
Properties
|
Property |
Modifiers |
Type |
Description |
|---|---|---|---|
|
string |
Collation of the index key, where it differs from the column's own. | ||
|
boolean |
Builds the index without locking writes out of the table. | ||
|
string |
Indexes this SQL expression rather than the column. | ||
|
string[] |
Extra columns to carry in the index without indexing them. | ||
|
Index method. Postgres uses | |||
|
string |
Name of the index. | ||
|
boolean |
| ||
|
string |
Operator class for the key. | ||
|
Sort direction of the index key. | |||
|
string |
Restricts the index to the rows this SQL condition matches. | ||
|
boolean |
Leaves an index that already exists alone rather than rebuilding it. | ||
|
string |
Tablespace to build the index in, instead of the database default. | ||
|
boolean |
Rejects duplicate values, enforcing uniqueness through the index. |