generated from VLADIMIR/template
up
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
-- +goose Up
|
||||
ALTER TABLE game_exports ADD COLUMN released_at TIMESTAMPTZ;
|
||||
DROP INDEX game_exports_active;
|
||||
CREATE UNIQUE INDEX game_exports_active ON game_exports(game_id)
|
||||
WHERE state IN ('preparing', 'ready') AND released_at IS NULL;
|
||||
|
||||
-- +goose Down
|
||||
-- Refuse rollback if retained ready exports cannot fit the old unique index.
|
||||
DROP INDEX game_exports_active;
|
||||
CREATE UNIQUE INDEX game_exports_active ON game_exports(game_id) WHERE state IN ('preparing', 'ready');
|
||||
ALTER TABLE game_exports DROP COLUMN released_at;
|
||||
Reference in New Issue
Block a user