From 95ef3078073647c84cc0d8a0b7c5c2d1644d7268 Mon Sep 17 00:00:00 2001 From: Cody Hansen Date: Thu, 8 Aug 2024 10:56:17 -1000 Subject: [PATCH] More migration fixes --- .../hasura/migrations/Aerie/9_sequence_workspaces/down.sql | 1 + deployment/hasura/migrations/Aerie/9_sequence_workspaces/up.sql | 2 ++ deployment/postgres-init-db/sql/applied_migrations.sql | 1 + 3 files changed, 4 insertions(+) diff --git a/deployment/hasura/migrations/Aerie/9_sequence_workspaces/down.sql b/deployment/hasura/migrations/Aerie/9_sequence_workspaces/down.sql index 4794f134bc..95dbc5a2fa 100644 --- a/deployment/hasura/migrations/Aerie/9_sequence_workspaces/down.sql +++ b/deployment/hasura/migrations/Aerie/9_sequence_workspaces/down.sql @@ -2,6 +2,7 @@ alter table sequencing.user_sequence drop constraint user_sequence_workspace_id_fkey, drop column workspace_id; +drop trigger set_timestamp on sequencing.workspace; drop table sequencing.workspace; call migrations.mark_migration_rolled_back('9'); diff --git a/deployment/hasura/migrations/Aerie/9_sequence_workspaces/up.sql b/deployment/hasura/migrations/Aerie/9_sequence_workspaces/up.sql index 7188ab6b12..7f45b4ac8e 100644 --- a/deployment/hasura/migrations/Aerie/9_sequence_workspaces/up.sql +++ b/deployment/hasura/migrations/Aerie/9_sequence_workspaces/up.sql @@ -51,3 +51,5 @@ values ('Workspace 1', 'Aerie Legacy'); update sequencing.user_sequence set workspace_id = 1; + +call migrations.mark_migration_applied('9'); diff --git a/deployment/postgres-init-db/sql/applied_migrations.sql b/deployment/postgres-init-db/sql/applied_migrations.sql index 064eafae07..4f0f55d200 100644 --- a/deployment/postgres-init-db/sql/applied_migrations.sql +++ b/deployment/postgres-init-db/sql/applied_migrations.sql @@ -11,3 +11,4 @@ call migrations.mark_migration_applied('5'); call migrations.mark_migration_applied('6'); call migrations.mark_migration_applied('7'); call migrations.mark_migration_applied('8'); +call migrations.mark_migration_applied('9');