Either an object of named bind parameter in the format $param
or an array of unnamed
bind parameter to replace $1
, $2
, ... in your SQL.
A sequelize instance used to build the return instance
A function that gets executed while running the query to log the sql.
Map returned fields to model's fields if options.model
or options.instance
is present.
Mapping will occur before building the model instance.
A sequelize model used to build the returned model instances (used to be called callee)
If 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
Defaults to false
Sets the query type to SELECT
and return a single row
If true, sequelize will not try to format the results of the query, or build an instance of a model from the result
Either an object of named parameter replacements in the format :param
or an array of unnamed
replacements to replace ?
in your SQL.
Set of flags that control when a query is automatically retried.
Append RETURNING * to get back auto generated values (Postgres only)
An optional parameter to specify the schema search_path (Postgres only)
If false do not prepend the query with the search_path (Postgres only)
Transaction to run query under
The type of query you are executing. The query type affects how results are formatted before they are
passed back. The type is a string, but Sequelize.QueryTypes
is provided as convenience shortcuts.
Force the query to use the write pool, regardless of the query type.
Defaults to false
Generated using TypeDoc
Interface for query options
Options