Documentation
    Preparing search index...

    Interface PersistedSequelizeOptions<Dialect>

    The options that are accessible via Sequelize#options.

    interface PersistedSequelizeOptions<Dialect extends AbstractDialect> {
        benchmark?: boolean;
        defaultTimestampPrecision?: number | null;
        defaultTransactionNestMode?: TransactionNestMode;
        define?: Omit<
            ModelOptions<Model<any, any>>,
            "name" | "tableName" | "modelName",
        >;
        disableClsTransactions?: boolean;
        isolationLevel?: IsolationLevel;
        keepDefaultTimezone?: boolean;
        logging?: false | ((sql: string, timing?: number) => void);
        logQueryParameters?: boolean;
        minifyAliases?: boolean;
        noTypeValidation?: boolean;
        nullJsonStringification?: "explicit" | "json" | "sql";
        omitNull?: boolean;
        prependSearchPath?: boolean;
        query?: QueryOptions;
        quoteIdentifiers?: boolean;
        replication?: false | Nullish | ReplicationOptions<Dialect>;
        retry?: Options;
        schema?: string;
        set?: DefaultSetOptions;
        sync?: SyncOptions;
        timezone?: string;
        transactionType?: TransactionType;
    }

    Type Parameters

    Hierarchy (View Summary)

    Index
    benchmark?: boolean

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

    defaultTimestampPrecision?: number | null

    The precision for the createdAt/updatedAt/deletedAt DATETIME columns that Sequelize adds to models. Can be a number between 0 and 6, or null to use the default precision of the database. Defaults to 6.

    6
    
    defaultTransactionNestMode?: TransactionNestMode

    How nested transaction blocks behave by default. See ManagedTransactionOptions#nestMode for more information.

    TransactionNestMode.reuse
    
    define?: Omit<ModelOptions<Model<any, any>>, "name" | "tableName" | "modelName">

    Default options for model definitions. See Model.init.

    disableClsTransactions?: boolean

    Disable the use of AsyncLocalStorage to automatically pass transactions started by Sequelize#transaction. You will need to pass transactions around manually if you disable this.

    isolationLevel?: IsolationLevel

    Set the default transaction isolation level. If not set, does not change the database's default transaction isolation level.

    keepDefaultTimezone?: boolean

    A flag that defines if the default timezone is used to convert dates from the database.

    false
    
    logging?: false | ((sql: string, timing?: number) => void)

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

    logQueryParameters?: boolean

    Set to true to show bind parameters in log.

    false
    
    minifyAliases?: boolean

    Set to true to automatically minify aliases generated by sequelize. Mostly useful to circumvent the POSTGRES alias limit of 64 characters.

    false
    
    noTypeValidation?: boolean

    Disable built in type validators on insert and update, e.g. don't validate that arguments passed to integer fields are integer-like.

    false
    
    nullJsonStringification?: "explicit" | "json" | "sql"

    When representing the JavaScript null primitive in a JSON column, Sequelize can use either the SQL NULL value, or a JSON 'null'.

    Set this to "json" if you want the null to be stored as a JSON 'null'. Set this to "sql" if you want the null to be stored as the SQL NULL value. Set this to "explicit" if you don't want Sequelize to make any assumptions. This means that you won't be able to use the JavaScript null primitive as the top level value of a JSON column, you will have to use @sequelize/core!SQL_NULL or @sequelize/core!JSON_NULL instead.

    This only impacts serialization when inserting or updating values. Comparing always requires to be explicit.

    Read more: https://sequelize.org/docs/v7/querying/json/

    json
    
    omitNull?: boolean

    A flag that defines if null values should be passed to SQL queries or not.

    false
    
    prependSearchPath?: boolean
    query?: QueryOptions

    Default options for sequelize.query

    quoteIdentifiers?: boolean

    Set to false to make table names and attributes case-insensitive on Postgres and skip double quoting of them.

    true
    
    replication?: false | Nullish | ReplicationOptions<Dialect>

    Use read / write replication. To enable replication, pass an object, with two properties, read and write. Write should be an object (a single server for handling writes), and read an array of object (several servers to handle reads). Each read/write server can have the following properties: host, port, username, password, database. Connection strings can be used instead of objects.

    false
    
    retry?: Options
    schema?: string

    If defined, the connection will use the provided schema instead of the default ("public").

    Default options for sequelize.set

    Default options for sequelize.sync

    timezone?: string

    The timezone used when converting a date from the database into a JavaScript date. The timezone is also used to SET TIMEZONE when connecting to the server, to ensure that the result of NOW, CURRENT_TIMESTAMP and other time related functions have in the right timezone. For best cross platform performance use the format +/-HH:MM. Will also accept string versions of timezones supported by Intl.Locale (e.g. 'America/Los_Angeles'); this is useful to capture daylight savings time changes.

    '+00:00'
    
    transactionType?: TransactionType

    Set the default transaction type. See Sequelize.Transaction.TYPES for possible options. Sqlite only.

    'DEFERRED'