From ca9ab2e374396f72399ea7ada15dd684f023ce05 Mon Sep 17 00:00:00 2001 From: Uhrin Attila Date: Thu, 5 Jan 2023 09:03:10 +0100 Subject: [PATCH] Add Flyway out of order migration scripts --- .../db/out-of-order-migration/V1_0__create_city_table.sql | 5 +++++ .../db/out-of-order-migration/V1_1__add_zipcode_to_city.sql | 3 +++ .../db/out-of-order-migration/V2_0__create_person_table.sql | 5 +++++ 3 files changed, 13 insertions(+) create mode 100644 persistence-modules/flyway/db/out-of-order-migration/V1_0__create_city_table.sql create mode 100644 persistence-modules/flyway/db/out-of-order-migration/V1_1__add_zipcode_to_city.sql create mode 100644 persistence-modules/flyway/db/out-of-order-migration/V2_0__create_person_table.sql diff --git a/persistence-modules/flyway/db/out-of-order-migration/V1_0__create_city_table.sql b/persistence-modules/flyway/db/out-of-order-migration/V1_0__create_city_table.sql new file mode 100644 index 0000000000..1c45a12fac --- /dev/null +++ b/persistence-modules/flyway/db/out-of-order-migration/V1_0__create_city_table.sql @@ -0,0 +1,5 @@ +create table city ( + id numeric, + name varchar(50), + constraint pk_city primary key (id) +); \ No newline at end of file diff --git a/persistence-modules/flyway/db/out-of-order-migration/V1_1__add_zipcode_to_city.sql b/persistence-modules/flyway/db/out-of-order-migration/V1_1__add_zipcode_to_city.sql new file mode 100644 index 0000000000..a619097071 --- /dev/null +++ b/persistence-modules/flyway/db/out-of-order-migration/V1_1__add_zipcode_to_city.sql @@ -0,0 +1,3 @@ +alter table city add column ( + zip varchar(10) +); \ No newline at end of file diff --git a/persistence-modules/flyway/db/out-of-order-migration/V2_0__create_person_table.sql b/persistence-modules/flyway/db/out-of-order-migration/V2_0__create_person_table.sql new file mode 100644 index 0000000000..19aa5e2ac7 --- /dev/null +++ b/persistence-modules/flyway/db/out-of-order-migration/V2_0__create_person_table.sql @@ -0,0 +1,5 @@ +create table person ( + id numeric, + name varchar(50), + constraint pk_person primary key (id) +); \ No newline at end of file