From: Galen Charlton Date: Tue, 21 Sep 2021 14:10:38 +0000 (-0400) Subject: LP#1737019: (follow-up) fix issue in schema update X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=1f25f132a0ebb50127588dab3f5d4ec2bf98d3b2;p=evergreen%2Ftadl.git LP#1737019: (follow-up) fix issue in schema update Looks like 'SET DEFAULT ...' and 'SET NOT NULL' cannot be combined in a single ALTER TABLE statement. Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.acq-active-flag.sql b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.acq-active-flag.sql index 4a5aeee8db..fce1555b86 100644 --- a/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.acq-active-flag.sql +++ b/Open-ILS/src/sql/Pg/upgrade/XXXX.schema.acq-active-flag.sql @@ -8,6 +8,7 @@ ALTER TABLE acq.funding_source ADD COLUMN active BOOL; UPDATE acq.funding_source SET active = 't'; -ALTER TABLE acq.funding_source ALTER COLUMN active SET NOT NULL DEFAULT TRUE; +ALTER TABLE acq.funding_source ALTER COLUMN active SET DEFAULT TRUE; +ALTER TABLE acq.funding_source ALTER COLUMN active SET NOT NULL; -COMMIT; \ No newline at end of file +COMMIT;