Skip to content

Commit

Permalink
(BIDS-2340) Fix performance xd columns (remove them from DB)
Browse files Browse the repository at this point in the history
  • Loading branch information
recy21 committed Aug 14, 2023
1 parent d3e02f2 commit 8cd8012
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions db/migrations/20230814224221_fix_performance_xd.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
-- +goose Up
-- +goose StatementBegin
SELECT 'delete all unneeded performance xd columns';
ALTER TABLE validator_performance DROP COLUMN IF EXISTS performance1d;
ALTER TABLE validator_performance DROP COLUMN IF EXISTS performance7d;
ALTER TABLE validator_performance DROP COLUMN IF EXISTS performance31d;
ALTER TABLE validator_performance DROP COLUMN IF EXISTS performance365d;
-- +goose StatementEnd

-- +goose Down
-- +goose StatementBegin
SELECT 'add all unneeded performance xd columns';
ALTER TABLE validator_stats ADD COLUMN IF NOT EXISTS performance1d BIGINT NOT NULL;
ALTER TABLE validator_stats ADD COLUMN IF NOT EXISTS performance7d BIGINT NOT NULL;
ALTER TABLE validator_stats ADD COLUMN IF NOT EXISTS performance31d BIGINT NOT NULL;
ALTER TABLE validator_stats ADD COLUMN IF NOT EXISTS performance365d BIGINT NOT NULL;
-- +goose StatementEnd

0 comments on commit 8cd8012

Please sign in to comment.