Reorder SQL to avoid race conditions (Liquibase #8)
This commit rearranges SQL statements to minimize race conditions
once the SQL is converted to seperate Liquibase steps.
When adding default values & not-null constraints, do it like this:
1. Set default value for the column, so any new data will not be NULL
2. Update any existing NULLs to that same default value
3. Add the NOT NULL constraint to the column
If DEFAULT is set after NOT NULL, it's possible new rows could be
added with NULL, causing the SET NOT NULL to fail.
Issue-ID: POLICY-5398
Change-Id: Ia9b10340fbd6a856d5e4b2aa059f0c8d59a2f070
Signed-off-by: danielhanrahan <daniel.hanrahan@est.tech>