summaryrefslogtreecommitdiff
path: root/db/post_migrate/20200916081749_remove_cycle_analytics_total_stage_data.rb
diff options
context:
space:
mode:
Diffstat (limited to 'db/post_migrate/20200916081749_remove_cycle_analytics_total_stage_data.rb')
-rw-r--r--db/post_migrate/20200916081749_remove_cycle_analytics_total_stage_data.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/db/post_migrate/20200916081749_remove_cycle_analytics_total_stage_data.rb b/db/post_migrate/20200916081749_remove_cycle_analytics_total_stage_data.rb
new file mode 100644
index 00000000000..94c218c0c57
--- /dev/null
+++ b/db/post_migrate/20200916081749_remove_cycle_analytics_total_stage_data.rb
@@ -0,0 +1,14 @@
+# frozen_string_literal: true
+
+class RemoveCycleAnalyticsTotalStageData < ActiveRecord::Migration[6.0]
+ DOWNTIME = false
+
+ def up
+ execute("DELETE FROM analytics_cycle_analytics_group_stages WHERE name='production'")
+ execute("DELETE FROM analytics_cycle_analytics_project_stages WHERE name='production'")
+ end
+
+ def down
+ # Migration is irreversible
+ end
+end