Index

pydantic model felis.datamodel.Index

Table index model.

An index can be defined on either columns or expressions, but not both.

Parameters:

data (Any)

Fields:
Validators:
field columns: list[str] | None = None

Columns in the index.

Validated by:
field expressions: list[str] | None = None

Expressions in the index.

Validated by:
validator check_columns_or_expressions  »  all fields

Check that columns or expressions are specified, but not both.

Parameters:

values (dict[str, Any]) – Values of the index.

Returns:

The values of the index.

Return type:

dict [ str, Any ]

Raises:

ValueError – Raised if both columns and expressions are specified, or if neither are specified.