interface SetIsolationLevelOptions {
    benchmark?: boolean;
    bind?: BindOrReplacements;
    fieldMap?: FieldMap;
    instance?: Model<any, any>;
    isolationLevel: IsolationLevel;
    logging?: false | ((sql, timing?) => void);
    mapToModel?: boolean;
    nest?: boolean;
    plain?: boolean;
    raw?: boolean;
    retry?: Options;
    type?: string;
    useMaster?: boolean;


  • Omit<QueryRawOptions, "connection" | "transaction" | "supportsSearchPath">
    • SetIsolationLevelOptions



Indicates if the query completes the transaction Internal only

benchmark?: boolean

Pass query execution time in milliseconds as second argument to logging function (options.logging).

Either 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.

fieldMap?: FieldMap

Map returned fields to arbitrary names for SELECT query type if options.fieldMaps is present.

instance?: Model<any, any>

A sequelize instance used to build the return instance

isolationLevel: IsolationLevel
logging?: false | ((sql, timing?) => void)

A function that gets executed while running the query to log the sql.

Type declaration

    • (sql, timing?): void
    • Parameters

      • sql: string
      • Optional timing: number

      Returns void

mapToModel?: boolean

Map returned fields to model's fields if options.model or options.instance is present. Mapping will occur before building the model instance.

nest?: boolean

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


plain?: boolean

Sets the query type to SELECT and return a single row

raw?: boolean

If true, sequelize will not try to format the results of the query, or build an instance of a model from the result

retry?: Options
type?: string

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.

useMaster?: boolean

Force the query to use the write pool, regardless of the query type.