File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed
cmd/hatchet-migrate/migrate/migrations Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,10 @@ ALTER TABLE "TenantResourceLimit"
1919 ALTER COLUMN resource TYPE " LimitResource_new"
2020 USING resource::text ::" LimitResource_new" ;
2121
22+ ALTER TABLE " TenantResourceLimitAlert"
23+ ALTER COLUMN resource TYPE " LimitResource_new"
24+ USING resource::text ::" LimitResource_new" ;
25+
2226DROP TYPE " LimitResource" CASCADE;
2327
2428ALTER TYPE " LimitResource_new" RENAME TO " LimitResource" ;
Original file line number Diff line number Diff line change 1+ -- +goose Up
2+ -- +goose StatementBegin
3+ -- Patches migration for previously incorrect migration (0.69)
4+ -- NOTE: the default here is just to backfill previous incorrect cols
5+ TRUNCATE TABLE " TenantResourceLimitAlert" ;
6+ ALTER TABLE " TenantResourceLimitAlert"
7+ ADD COLUMN IF NOT EXISTS " resource" " LimitResource" NOT NULL ;
8+ -- +goose StatementEnd
9+
10+ -- +goose Down
11+ -- +goose StatementBegin
12+ -- Intentionally left empty since this migration is only for adding the column for incorrect previous migration
13+ -- +goose StatementEnd
You can’t perform that action at this time.
0 commit comments