mirror of
https://github.com/ebean-orm/ebean.git
synced 2024-04-21 10:51:47 +00:00
Add: ElementCollection
This commit is contained in:
@@ -14,6 +14,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
migtest_mtm_c_id UInt32
|
||||
) ENGINE = Log();
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id UInt64,
|
||||
value String
|
||||
) ENGINE = Log();
|
||||
|
||||
alter table migtest_ckey_detail add column one_key UInt32;
|
||||
alter table migtest_ckey_detail add column two_key String;
|
||||
|
||||
|
||||
+1
@@ -31,3 +31,4 @@ alter table migtest_oto_child drop column master_id;
|
||||
drop table if exists migtest_e_user;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
79609527, 1.0__initial.sql
|
||||
-779316787, 1.1.sql
|
||||
1864520180, 1.1.sql
|
||||
1359055889, 1.2__dropsFor_1.1.sql
|
||||
-715327671, 1.3.sql
|
||||
-1070218324, 1.4__dropsFor_1.3.sql
|
||||
-1045594368, 1.4__dropsFor_1.3.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -106,6 +111,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
+1
@@ -36,3 +36,4 @@ drop table if exists migtest_e_user cascade;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m cascade;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c cascade;
|
||||
drop table if exists migtest_mtm_m_phone_numbers cascade;
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
-487576609, 1.0__initial.sql
|
||||
-889791572, 1.1.sql
|
||||
-1108404951, 1.1.sql
|
||||
-91524786, 1.2__dropsFor_1.1.sql
|
||||
735879716, 1.3.sql
|
||||
-807148201, 1.4__dropsFor_1.3.sql
|
||||
676584941, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -40,7 +45,8 @@ alter table migtest_e_basic alter column status2 set data type varchar(127);
|
||||
alter table migtest_e_basic alter column status2 drop default;
|
||||
alter table migtest_e_basic alter column status2 drop not null;
|
||||
|
||||
-- rename all collisions;
|
||||
-- db2 does not support parial null indices :( - so we have to clean;
|
||||
update migtest_e_basic set status = 'N' where id = 1;
|
||||
create unique index uq_migtest_e_basic_description on migtest_e_basic(description) exclude null keys;
|
||||
|
||||
insert into migtest_e_user (id) select distinct user_id from migtest_e_basic;
|
||||
@@ -103,6 +109,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict;
|
||||
|
||||
|
||||
@@ -32,3 +32,4 @@ drop table migtest_e_user;
|
||||
drop sequence migtest_e_user_seq;
|
||||
drop table migtest_mtm_c_migtest_mtm_m;
|
||||
drop table migtest_mtm_m_migtest_mtm_c;
|
||||
drop table migtest_mtm_m_phone_numbers;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
1580812656, 1.0__initial.sql
|
||||
1011854984, 1.1.sql
|
||||
1615151513, 1.1.sql
|
||||
578073685, 1.2__dropsFor_1.1.sql
|
||||
-1206650320, 1.3.sql
|
||||
-1475628451, 1.4__dropsFor_1.3.sql
|
||||
441227910, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -103,6 +108,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -31,3 +31,4 @@ alter table migtest_oto_child drop column master_id;
|
||||
drop table if exists migtest_e_user;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
-1827577042, 1.0__initial.sql
|
||||
350584020, 1.1.sql
|
||||
-1825206641, 1.1.sql
|
||||
1359055889, 1.2__dropsFor_1.1.sql
|
||||
297569863, 1.3.sql
|
||||
-1070218324, 1.4__dropsFor_1.3.sql
|
||||
-1045594368, 1.4__dropsFor_1.3.sql
|
||||
|
||||
|
||||
@@ -23,6 +23,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -114,6 +119,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -46,6 +46,7 @@ drop table if exists migtest_e_user;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
create view migtest_e_history2_with_history as select * from migtest_e_history2 union all select * from migtest_e_history2_history;
|
||||
|
||||
create view migtest_e_history5_with_history as select * from migtest_e_history5 union all select * from migtest_e_history5_history;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
-745768926, 1.0__initial.sql
|
||||
39858255, 1.1.sql
|
||||
1409369419, 1.1.sql
|
||||
1616986842, 1.2__dropsFor_1.1.sql
|
||||
-1513154593, 1.3.sql
|
||||
374569329, 1.4__dropsFor_1.3.sql
|
||||
1549130952, 1.4__dropsFor_1.3.sql
|
||||
783227075, R__multi_comments.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create column table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create column table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value nvarchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add ( one_key integer);
|
||||
alter table migtest_ckey_detail add ( two_key nvarchar(127));
|
||||
|
||||
@@ -162,6 +167,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
-- explicit index "ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c" for single column "migtest_mtm_c_id" of table "migtest_mtm_m_migtest_mtm_c" is not necessary;
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
-- explicit index "ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id" for single column "migtest_mtm_m_id" of table "migtest_mtm_m_phone_numbers" is not necessary;
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
-- explicit index "ix_migtest_ckey_parent_assoc_id" for single column "assoc_id" of table "migtest_ckey_parent" is not necessary;
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -49,3 +49,4 @@ CALL usp_ebean_drop_column('migtest_oto_child', 'master_id');
|
||||
drop table migtest_e_user cascade;
|
||||
drop table migtest_mtm_c_migtest_mtm_m cascade;
|
||||
drop table migtest_mtm_m_migtest_mtm_c cascade;
|
||||
drop table migtest_mtm_m_phone_numbers cascade;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
-1536923954, 1.0__initial.sql
|
||||
1039838314, 1.1.sql
|
||||
-1152055114, 1.1.sql
|
||||
562867593, 1.2__dropsFor_1.1.sql
|
||||
1566488731, 1.3.sql
|
||||
1030652294, 1.4__dropsFor_1.3.sql
|
||||
201970227, 1.4__dropsFor_1.3.sql
|
||||
1906063401, R__order_views_hana.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -103,6 +108,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -32,3 +32,4 @@ drop table if exists migtest_e_user;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
2097980375, 1.0__initial.sql
|
||||
2086418403, 1.1.sql
|
||||
-865579750, 1.1.sql
|
||||
-1462014216, 1.2__dropsFor_1.1.sql
|
||||
-2039573992, 1.3.sql
|
||||
2106151405, 1.4__dropsFor_1.3.sql
|
||||
-1763496614, 1.4__dropsFor_1.3.sql
|
||||
861001272, R__order_views_hsqldb.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -60,6 +65,7 @@ alter table migtest_e_history modify test_string bigint;
|
||||
alter table migtest_e_history comment = 'We have history now';
|
||||
|
||||
-- NOTE: table has @History - special migration may be necessary
|
||||
SET @@system_versioning_alter_history = 1;
|
||||
update migtest_e_history2 set test_string = 'unknown' where test_string is null;
|
||||
alter table migtest_e_history2 alter test_string set default 'unknown';
|
||||
alter table migtest_e_history2 modify test_string varchar(255) not null;
|
||||
@@ -96,6 +102,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
+1
@@ -32,4 +32,5 @@ drop table if exists migtest_e_user;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
alter table migtest_e_history drop system versioning;
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
1615386118, 1.0__initial.sql
|
||||
1747697741, 1.1.sql
|
||||
128637084, 1.1.sql
|
||||
-1462014216, 1.2__dropsFor_1.1.sql
|
||||
-1957738355, 1.3.sql
|
||||
1081793242, 1.4__dropsFor_1.3.sql
|
||||
89701608, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -60,6 +65,7 @@ alter table migtest_e_history modify test_string bigint;
|
||||
alter table migtest_e_history comment = 'We have history now';
|
||||
|
||||
-- NOTE: table has @History - special migration may be necessary
|
||||
SET @@system_versioning_alter_history = 1;
|
||||
update migtest_e_history2 set test_string = 'unknown' where test_string is null;
|
||||
alter table migtest_e_history2 alter test_string set default 'unknown';
|
||||
alter table migtest_e_history2 modify test_string varchar(255) not null;
|
||||
@@ -96,6 +102,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -32,4 +32,5 @@ drop table if exists migtest_e_user;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
alter table migtest_e_history drop system versioning;
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
1835064798, I__create_procs.sql
|
||||
1615386118, 1.0__initial.sql
|
||||
1747697741, 1.1.sql
|
||||
128637084, 1.1.sql
|
||||
-116088700, 1.2__dropsFor_1.1.sql
|
||||
-1957738355, 1.3.sql
|
||||
1065918589, 1.4__dropsFor_1.3.sql
|
||||
930722740, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -16,6 +16,10 @@
|
||||
<alterColumn columnName="status" tableName="migtest_e_basic" currentType="varchar(1)" defaultValue="'A'" notnull="true" currentNotnull="false" checkConstraint="check ( status in ('N','A','I','?'))" checkConstraintName="ck_migtest_e_basic_status"/>
|
||||
<alterColumn columnName="status2" tableName="migtest_e_basic" type="varchar(127)" currentType="varchar(1)" defaultValue="DROP DEFAULT" notnull="false" currentNotnull="true" dropCheckConstraint="ck_migtest_e_basic_status2"/>
|
||||
<alterColumn columnName="description" tableName="migtest_e_basic" unique="uq_migtest_e_basic_description">
|
||||
<before platforms="db2">
|
||||
<ddl>-- db2 does not support parial null indices :( - so we have to clean</ddl>
|
||||
<ddl>update ${table} set status = 'N' where id = 1</ddl>
|
||||
</before>
|
||||
<before>
|
||||
<ddl>-- rename all collisions</ddl>
|
||||
</before>
|
||||
@@ -50,7 +54,15 @@
|
||||
</before>
|
||||
</alterColumn>
|
||||
<addTableComment name="migtest_e_history" comment="We have history now"/>
|
||||
<alterColumn columnName="test_string" tableName="migtest_e_history2" withHistory="true" currentType="varchar" defaultValue="'unknown'" notnull="true" currentNotnull="false"/>
|
||||
<alterColumn columnName="test_string" tableName="migtest_e_history2" withHistory="true" currentType="varchar" defaultValue="'unknown'" notnull="true" currentNotnull="false">
|
||||
<before platforms="mariadb">
|
||||
<ddl>SET @@system_versioning_alter_history = 1</ddl>
|
||||
<ddl>update ${table} set ${column} = 'unknown' where ${column} is null</ddl>
|
||||
</before>
|
||||
<before>
|
||||
<ddl>update ${table} set ${column} = 'unknown' where ${column} is null</ddl>
|
||||
</before>
|
||||
</alterColumn>
|
||||
<addColumn tableName="migtest_e_history2" withHistory="true">
|
||||
<column name="test_string2" type="varchar" historyExclude="true"/>
|
||||
<column name="test_string3" type="varchar" defaultValue="'unknown'" notnull="true"/>
|
||||
@@ -81,6 +93,10 @@
|
||||
<foreignKey name="fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_m" columnNames="migtest_mtm_m_id" refColumnNames="id" refTableName="migtest_mtm_m" indexName="ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_m"/>
|
||||
<foreignKey name="fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c" columnNames="migtest_mtm_c_id" refColumnNames="id" refTableName="migtest_mtm_c" indexName="ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c"/>
|
||||
</createTable>
|
||||
<createTable name="migtest_mtm_m_phone_numbers" pkName="pk_migtest_mtm_m_phone_numbers">
|
||||
<column name="migtest_mtm_m_id" type="bigint" notnull="true" references="migtest_mtm_m.id" foreignKeyName="fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id" foreignKeyIndex="ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id"/>
|
||||
<column name="value" type="varchar" notnull="true"/>
|
||||
</createTable>
|
||||
<addColumn tableName="migtest_oto_child">
|
||||
<column name="master_id" type="bigint" uniqueOneToOne="uq_migtest_oto_child_master_id" references="migtest_oto_master.id" foreignKeyName="fk_migtest_oto_child_master_id"/>
|
||||
</addColumn>
|
||||
|
||||
@@ -69,5 +69,6 @@
|
||||
<dropTable name="migtest_e_user" sequenceCol="id"/>
|
||||
<dropTable name="migtest_mtm_c_migtest_mtm_m"/>
|
||||
<dropTable name="migtest_mtm_m_migtest_mtm_c"/>
|
||||
<dropTable name="migtest_mtm_m_phone_numbers"/>
|
||||
</changeSet>
|
||||
</migration>
|
||||
+1
@@ -19,5 +19,6 @@
|
||||
<dropTable name="migtest_e_user" sequenceCol="id"/>
|
||||
<dropTable name="migtest_mtm_c_migtest_mtm_m"/>
|
||||
<dropTable name="migtest_mtm_m_migtest_mtm_c"/>
|
||||
<dropTable name="migtest_mtm_m_phone_numbers"/>
|
||||
</changeSet>
|
||||
</migration>
|
||||
@@ -23,6 +23,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -107,6 +112,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -46,6 +46,7 @@ CALL usp_ebean_drop_column('migtest_oto_child', 'master_id');
|
||||
drop table if exists migtest_e_user;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
create view migtest_e_history2_with_history as select * from migtest_e_history2 union all select * from migtest_e_history2_history;
|
||||
|
||||
create view migtest_e_history5_with_history as select * from migtest_e_history5 union all select * from migtest_e_history5_history;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
1835064798, I__create_procs.sql
|
||||
-1087663151, 1.0__initial.sql
|
||||
880212944, 1.1.sql
|
||||
-1627573867, 1.1.sql
|
||||
1922991807, 1.2__dropsFor_1.1.sql
|
||||
-380371830, 1.3.sql
|
||||
-1139228843, 1.4__dropsFor_1.3.sql
|
||||
-1373040825, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -23,6 +23,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -112,6 +117,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id);
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id);
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id);
|
||||
|
||||
|
||||
@@ -47,6 +47,7 @@ drop table if exists migtest_e_user;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
create view migtest_e_history2_with_history as select * from migtest_e_history2 union all select * from migtest_e_history2_history;
|
||||
|
||||
create view migtest_e_history5_with_history as select * from migtest_e_history5 union all select * from migtest_e_history5_history;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
-600390912, 1.0__initial.sql
|
||||
85177147, 1.1.sql
|
||||
667708916, 1.1.sql
|
||||
-1171866240, 1.2__dropsFor_1.1.sql
|
||||
870952105, 1.3.sql
|
||||
560246183, 1.4__dropsFor_1.3.sql
|
||||
473283202, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -18,6 +18,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id number(19) not null,
|
||||
value varchar2(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add one_key number(10);
|
||||
alter table migtest_ckey_detail add two_key varchar2(127);
|
||||
|
||||
@@ -104,6 +109,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_mgtst_mtm_m_mgtst_mt_g
|
||||
create index ix_mgtst_mtm_m_mgtst_mt_b7nbck on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_mgtst_mtm_m_mgtst_mt_ggi34a foreign key (migtest_mtm_c_id) references migtest_mtm_c (id);
|
||||
|
||||
create index ix_mgtst_mtm_m_phn_nmbr_do9ma3 on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_mgtst_mtm_m_phn_nmbr_s8neid foreign key (migtest_mtm_m_id) references migtest_mtm_m (id);
|
||||
|
||||
create index ix_mgtst_cky_prnt_ssc_d on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_mgtst_cky_prnt_ssc_d foreign key (assoc_id) references migtest_ckey_assoc (id);
|
||||
|
||||
|
||||
@@ -32,3 +32,4 @@ drop table migtest_e_user cascade constraints purge;
|
||||
drop sequence migtest_e_user_seq;
|
||||
drop table migtest_mtm_c_migtest_mtm_m cascade constraints purge;
|
||||
drop table migtest_mtm_m_migtest_mtm_c cascade constraints purge;
|
||||
drop table migtest_mtm_m_phone_numbers cascade constraints purge;
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
1839897438, 1.0__initial.sql
|
||||
1699280801, 1.1.sql
|
||||
1927010726, 1.1.sql
|
||||
238598298, 1.2__dropsFor_1.1.sql
|
||||
1543053715, 1.3.sql
|
||||
1213528478, 1.4__dropsFor_1.3.sql
|
||||
-629809805, 1.4__dropsFor_1.3.sql
|
||||
1357801733, R__oracle_only_views.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
@@ -23,6 +23,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -120,6 +125,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -47,6 +47,7 @@ drop table if exists migtest_e_user cascade;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m cascade;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c cascade;
|
||||
drop table if exists migtest_mtm_m_phone_numbers cascade;
|
||||
create view migtest_e_history2_with_history as select * from migtest_e_history2 union all select * from migtest_e_history2_history;
|
||||
|
||||
create view migtest_e_history5_with_history as select * from migtest_e_history5 union all select * from migtest_e_history5_history;
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
1428934272, 1.0__initial.sql
|
||||
-1309302980, 1.1.sql
|
||||
1253246780, 1.1.sql
|
||||
-1861367028, 1.2__dropsFor_1.1.sql
|
||||
326342179, 1.3.sql
|
||||
1959776888, 1.4__dropsFor_1.3.sql
|
||||
-1991941691, 1.4__dropsFor_1.3.sql
|
||||
783227075, R__multi_comments.sql
|
||||
561281075, R__order_views.sql
|
||||
283077354, R__pg_indexes.sql
|
||||
|
||||
@@ -17,6 +17,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id numeric(19) not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -103,6 +108,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
+1
@@ -31,3 +31,4 @@ alter table migtest_oto_child drop column master_id;
|
||||
drop table if exists migtest_e_user;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
471098770, 1.0__initial.sql
|
||||
-1404654186, 1.1.sql
|
||||
776493598, 1.1.sql
|
||||
1359055889, 1.2__dropsFor_1.1.sql
|
||||
-1656705954, 1.3.sql
|
||||
-1070218324, 1.4__dropsFor_1.3.sql
|
||||
-1045594368, 1.4__dropsFor_1.3.sql
|
||||
|
||||
|
||||
@@ -21,6 +21,12 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id integer not null,
|
||||
value varchar(255) not null,
|
||||
foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
|
||||
@@ -31,3 +31,4 @@ alter table migtest_oto_child drop column master_id;
|
||||
drop table if exists migtest_e_user;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c;
|
||||
drop table if exists migtest_mtm_m_phone_numbers;
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
1429491518, 1.0__initial.sql
|
||||
-347121868, 1.1.sql
|
||||
-1974335860, 1.1.sql
|
||||
1359055889, 1.2__dropsFor_1.1.sql
|
||||
-1764531063, 1.3.sql
|
||||
-1070218324, 1.4__dropsFor_1.3.sql
|
||||
-1045594368, 1.4__dropsFor_1.3.sql
|
||||
2034589659, R__order_views_sqlite.sql
|
||||
|
||||
|
||||
@@ -18,6 +18,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id numeric(19) not null,
|
||||
value nvarchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add one_key integer;
|
||||
alter table migtest_ckey_detail add two_key nvarchar(127);
|
||||
|
||||
@@ -103,6 +108,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id);
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id);
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id);
|
||||
|
||||
|
||||
+1
@@ -32,6 +32,7 @@ IF OBJECT_ID('migtest_e_user', 'U') IS NOT NULL drop table migtest_e_user;
|
||||
IF OBJECT_ID('migtest_e_user_seq', 'SO') IS NOT NULL drop sequence migtest_e_user_seq;
|
||||
IF OBJECT_ID('migtest_mtm_c_migtest_mtm_m', 'U') IS NOT NULL drop table migtest_mtm_c_migtest_mtm_m;
|
||||
IF OBJECT_ID('migtest_mtm_m_migtest_mtm_c', 'U') IS NOT NULL drop table migtest_mtm_m_migtest_mtm_c;
|
||||
IF OBJECT_ID('migtest_mtm_m_phone_numbers', 'U') IS NOT NULL drop table migtest_mtm_m_phone_numbers;
|
||||
-- dropping history support for migtest_e_history;
|
||||
EXEC usp_ebean_drop_default_constraint migtest_e_history, sys_periodFrom;
|
||||
EXEC usp_ebean_drop_default_constraint migtest_e_history, sys_periodTo;
|
||||
|
||||
+2
-2
@@ -1,8 +1,8 @@
|
||||
-2122378240, I__create_procs.sql
|
||||
-1048913407, 1.0__initial.sql
|
||||
615613536, 1.1.sql
|
||||
-898063858, 1.1.sql
|
||||
-1805601919, 1.2__dropsFor_1.1.sql
|
||||
-1791137342, 1.3.sql
|
||||
460536923, 1.4__dropsFor_1.3.sql
|
||||
-1335541264, 1.4__dropsFor_1.3.sql
|
||||
1607822082, R__order_views_mssql.sql
|
||||
|
||||
|
||||
@@ -23,6 +23,11 @@ create table migtest_mtm_m_migtest_mtm_c (
|
||||
constraint pk_migtest_mtm_m_migtest_mtm_c primary key (migtest_mtm_m_id,migtest_mtm_c_id)
|
||||
);
|
||||
|
||||
create table migtest_mtm_m_phone_numbers (
|
||||
migtest_mtm_m_id bigint not null,
|
||||
value varchar(255) not null
|
||||
);
|
||||
|
||||
alter table migtest_ckey_detail add column one_key integer;
|
||||
alter table migtest_ckey_detail add column two_key varchar(127);
|
||||
|
||||
@@ -114,6 +119,9 @@ alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_
|
||||
create index ix_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c on migtest_mtm_m_migtest_mtm_c (migtest_mtm_c_id);
|
||||
alter table migtest_mtm_m_migtest_mtm_c add constraint fk_migtest_mtm_m_migtest_mtm_c_migtest_mtm_c foreign key (migtest_mtm_c_id) references migtest_mtm_c (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_mtm_m_phone_numbers_migtest_mtm_m_id on migtest_mtm_m_phone_numbers (migtest_mtm_m_id);
|
||||
alter table migtest_mtm_m_phone_numbers add constraint fk_migtest_mtm_m_phone_numbers_migtest_mtm_m_id foreign key (migtest_mtm_m_id) references migtest_mtm_m (id) on delete restrict on update restrict;
|
||||
|
||||
create index ix_migtest_ckey_parent_assoc_id on migtest_ckey_parent (assoc_id);
|
||||
alter table migtest_ckey_parent add constraint fk_migtest_ckey_parent_assoc_id foreign key (assoc_id) references migtest_ckey_assoc (id) on delete restrict on update restrict;
|
||||
|
||||
|
||||
@@ -47,6 +47,7 @@ drop table if exists migtest_e_user cascade;
|
||||
drop sequence if exists migtest_e_user_seq;
|
||||
drop table if exists migtest_mtm_c_migtest_mtm_m cascade;
|
||||
drop table if exists migtest_mtm_m_migtest_mtm_c cascade;
|
||||
drop table if exists migtest_mtm_m_phone_numbers cascade;
|
||||
create view migtest_e_history2_with_history as select * from migtest_e_history2 union all select * from migtest_e_history2_history;
|
||||
|
||||
create view migtest_e_history5_with_history as select * from migtest_e_history5 union all select * from migtest_e_history5_history;
|
||||
|
||||
+2
-2
@@ -1,7 +1,7 @@
|
||||
-1449071956, 1.0__initial.sql
|
||||
1483502951, 1.1.sql
|
||||
1985413053, 1.1.sql
|
||||
-1861367028, 1.2__dropsFor_1.1.sql
|
||||
2034977550, 1.3.sql
|
||||
1959776888, 1.4__dropsFor_1.3.sql
|
||||
-1991941691, 1.4__dropsFor_1.3.sql
|
||||
561281075, R__order_views.sql
|
||||
|
||||
|
||||
Reference in New Issue
Block a user