From 6610821833228934e658100ccd4b4f54071e0471 Mon Sep 17 00:00:00 2001 From: Edvard Date: Fri, 26 Oct 2018 15:25:27 +0200 Subject: [PATCH] Squash cat_file checked_headers --- db/migrations/1536765047_create_cat_file.down.sql | 12 ++++++++++++ ...bles.up.sql => 1536765047_create_cat_file.up.sql} | 11 ++++++++++- .../1536765047_create_cat_file_tables.down.sql | 3 --- ...t_file_checked_fields_to_checked_headers.down.sql | 6 ------ ...cat_file_checked_fields_to_checked_headers.up.sql | 6 ------ 5 files changed, 22 insertions(+), 16 deletions(-) create mode 100644 db/migrations/1536765047_create_cat_file.down.sql rename db/migrations/{1536765047_create_cat_file_tables.up.sql => 1536765047_create_cat_file.up.sql} (76%) delete mode 100644 db/migrations/1536765047_create_cat_file_tables.down.sql delete mode 100644 db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.down.sql delete mode 100644 db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.up.sql diff --git a/db/migrations/1536765047_create_cat_file.down.sql b/db/migrations/1536765047_create_cat_file.down.sql new file mode 100644 index 00000000..6a58fbc1 --- /dev/null +++ b/db/migrations/1536765047_create_cat_file.down.sql @@ -0,0 +1,12 @@ +DROP TABLE maker.cat_file_chop_lump; +DROP TABLE maker.cat_file_flip; +DROP TABLE maker.cat_file_pit_vow; + +ALTER TABLE public.checked_headers + DROP COLUMN cat_file_chop_lump_checked; + +ALTER TABLE public.checked_headers + DROP COLUMN cat_file_flip_checked; + +ALTER TABLE public.checked_headers + DROP COLUMN cat_file_pit_vow_checked; \ No newline at end of file diff --git a/db/migrations/1536765047_create_cat_file_tables.up.sql b/db/migrations/1536765047_create_cat_file.up.sql similarity index 76% rename from db/migrations/1536765047_create_cat_file_tables.up.sql rename to db/migrations/1536765047_create_cat_file.up.sql index c682e625..100c14e6 100644 --- a/db/migrations/1536765047_create_cat_file_tables.up.sql +++ b/db/migrations/1536765047_create_cat_file.up.sql @@ -31,4 +31,13 @@ CREATE TABLE maker.cat_file_pit_vow ( log_idx INTEGER NOT NULL, raw_log JSONB, UNIQUE (header_id, tx_idx, log_idx) -); \ No newline at end of file +); + +ALTER TABLE public.checked_headers + ADD COLUMN cat_file_chop_lump_checked BOOLEAN NOT NULL DEFAULT FALSE; + +ALTER TABLE public.checked_headers + ADD COLUMN cat_file_flip_checked BOOLEAN NOT NULL DEFAULT FALSE; + +ALTER TABLE public.checked_headers + ADD COLUMN cat_file_pit_vow_checked BOOLEAN NOT NULL DEFAULT FALSE; \ No newline at end of file diff --git a/db/migrations/1536765047_create_cat_file_tables.down.sql b/db/migrations/1536765047_create_cat_file_tables.down.sql deleted file mode 100644 index eb2bdb55..00000000 --- a/db/migrations/1536765047_create_cat_file_tables.down.sql +++ /dev/null @@ -1,3 +0,0 @@ -DROP TABLE maker.cat_file_chop_lump; -DROP TABLE maker.cat_file_flip; -DROP TABLE maker.cat_file_pit_vow; \ No newline at end of file diff --git a/db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.down.sql b/db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.down.sql deleted file mode 100644 index 46694237..00000000 --- a/db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.down.sql +++ /dev/null @@ -1,6 +0,0 @@ -ALTER TABLE public.checked_headers - DROP COLUMN cat_file_chop_lump_checked; -ALTER TABLE public.checked_headers - DROP COLUMN cat_file_flip_checked; -ALTER TABLE public.checked_headers - DROP COLUMN cat_file_pit_vow_checked; diff --git a/db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.up.sql b/db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.up.sql deleted file mode 100644 index ef608eb9..00000000 --- a/db/migrations/1537899079_add_cat_file_checked_fields_to_checked_headers.up.sql +++ /dev/null @@ -1,6 +0,0 @@ -ALTER TABLE public.checked_headers - ADD COLUMN cat_file_chop_lump_checked BOOLEAN NOT NULL DEFAULT FALSE; -ALTER TABLE public.checked_headers - ADD COLUMN cat_file_flip_checked BOOLEAN NOT NULL DEFAULT FALSE; -ALTER TABLE public.checked_headers - ADD COLUMN cat_file_pit_vow_checked BOOLEAN NOT NULL DEFAULT FALSE;