mirror of
https://github.com/GSA/notifications-api.git
synced 2026-05-30 02:49:41 -04:00
A not valid constraint only checks against new rows, not existing rows. We can call VALIDATE CONSTRAINT against this new constraint to check the old rows (which we know are good, having run the command from74961781). Adding a normal constraint acquires an ACCESS EXCLUSIVE lock, but validate constraint only needs a SHARE UPDATE EXCLUSIVE lock. see9d4b8961and0a50993ffor more information on marking constraints as not valid.
Generic single-database configuration.
flask db migrate to generate migration script.
flask db upgrade to upgrade db with script.
flask db downgrade to rollback db changes.
flask db current to show current script.