debian-koji/docs/schema-update-1.31-1.32.sql
2023-02-01 15:01:15 +01:00

13 lines
530 B
PL/PgSQL

-- upgrade script to migrate the Koji database schema
-- from version 1.31 to 1.32
BEGIN;
-- fix duplicate extension in archivetypes
UPDATE archivetypes SET extensions = 'vhdx.gz vhdx.xz' WHERE name = 'vhdx-compressed';
-- for tag if session is closed or not
ALTER TABLE sessions ADD COLUMN closed BOOLEAN NOT NULL DEFAULT FALSE;
ALTER TABLE sessions ADD CONSTRAINT no_closed_exclusive CHECK (closed IS FALSE OR "exclusive" IS NULL);
ALTER TABLE sessions DROP CONSTRAINT exclusive_expired_sane;
COMMIT;