How do you define a composite index in EdgeDB?
The simplest form of index is an index, which references one or more properties directly:
type User { property name -> str; index on (__subject__.name); }
but I couldn't find a way to reference multiple properties in an index.
You can add
index on (...)
to the containing type, where...
is an arbitrary scalar expression. To create a composite index it should be a tuple(x, y)
:source