Deferrable

Deferrable

When you specify a foreign key column it is optionally possible to declare the deferrabletype in PostgreSQL. The following options are available:

// Defer all foreign key constraint check to the end of a transaction
Sequelize.Deferrable.INITIALLY_DEFERRED

// Immediately check the foreign key constraints
Sequelize.Deferrable.INITIALLY_IMMEDIATE

// Don't defer the checks at all
Sequelize.Deferrable.NOT

The last option is the default in PostgreSQL and won‘t allow you to dynamically changethe rule in a transaction. See the transaction section for further information.