OptionalbenchmarkOptionalbindEither an object of named parameter bindings in the format $param or an array of unnamed
values to bind to $1, $2, etc in your SQL.
OptionalconcurrentlyPostgreSQL will build the index without taking any write locks. Postgres only.
OptionalconnectionThe connection on which this query must be run. Mutually exclusive with Transactionable.transaction.
Can be used to ensure that a query is run on the same connection as a previous query, which is useful when configuring session options.
Specifying this option takes precedence over CLS Transactions. If a transaction is running in the current AsyncLocalStorage context, it will be ignored in favor of the specified connection.
OptionalfieldMap returned fields to arbitrary names for SELECT query type if options.fieldMaps is present.
OptionalfieldsThe fields to index.
OptionalincludeNon-key columns to be added to the lead level of the nonclustered index.
OptionalinstanceA sequelize instance used to build the return instance
OptionalloggingA function that gets executed while running the query to log the sql.
OptionalmapMap returned fields to model's fields if options.model or options.instance is present.
Mapping will occur before building the model instance.
OptionalmsgThe message to display if the unique constraint is violated.
OptionalnameThe name of the index. Defaults to model name + _ + fields concatenated
OptionalnestIf true, transforms objects with . separated property names into nested objects using
dottie.js. For example { 'user.username': 'john' } becomes
{ user: { username: 'john' }}. When nest is true, the query type is assumed to be 'SELECT',
unless otherwise specified
OptionaloperatorIndex operator type. Postgres only
OptionalparserFor FULLTEXT columns set your parser
OptionalplainSets the query type to SELECT and return a single row
OptionalprefixPrefix to append to the index name.
OptionalrawIf true, sequelize will not try to format the results of the query, or build an instance of a model from the result
OptionalreplacementsOnly named replacements are allowed in query interface methods.
OptionalretryOptionalsupportsIf false do not prepend the query with the search_path (Postgres only)
OptionaltransactionThe transaction in which this query must be run. Mutually exclusive with Transactionable.connection.
If the Sequelize disableClsTransactions option has not been set to true, and a transaction is running in the current AsyncLocalStorage context, that transaction will be used, unless null or another Transaction is manually specified here.
OptionaltypeIndex type. Only used by mysql. One of UNIQUE, FULLTEXT and SPATIAL
OptionaluniqueShould the index by unique? Can also be triggered by setting type to UNIQUE
OptionaluseForce the query to use the write pool, regardless of the query type.
OptionalusingThe method to create the index by (USING statement in SQL).
BTREE and HASH are supported by mysql and postgres.
Postgres additionally supports GIST, SPGIST, BRIN and GIN.
OptionalwhereOptional where parameter for index. Can be used to limit the index to certain rows.
Pass query execution time in milliseconds as second argument to logging function (options.logging).