mirror of
https://github.com/ebean-orm/ebean.git
synced 2026-11-23 15:12:58 +00:00
#1281 - Test change only - Update DbMigrationTest for SQL Server using SEQUENCE based Identity
This commit is contained in:
1 parent
58def02cd1
commit
a3e5c3a786
5 files changed
+35
-21
No files matched your search
@@ -1,41 +1,48 @@
|
||||
-- Migrationscripts for ebean unittest
|
||||
-- apply changes
|
||||
create table migtest_fk_cascade (
|
||||
id numeric(19) identity(1,1) not null,
|
||||
id numeric(19) not null,
|
||||
one_id numeric(19),
|
||||
constraint pk_migtest_fk_cascade primary key (id)
|
||||
);
|
||||
create sequence migtest_fk_cascade_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_fk_cascade_one (
|
||||
id numeric(19) identity(1,1) not null,
|
||||
id numeric(19) not null,
|
||||
constraint pk_migtest_fk_cascade_one primary key (id)
|
||||
);
|
||||
create sequence migtest_fk_cascade_one_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_fk_none (
|
||||
id numeric(19) identity(1,1) not null,
|
||||
id numeric(19) not null,
|
||||
one_id numeric(19),
|
||||
constraint pk_migtest_fk_none primary key (id)
|
||||
);
|
||||
create sequence migtest_fk_none_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_fk_none_via_join (
|
||||
id numeric(19) identity(1,1) not null,
|
||||
id numeric(19) not null,
|
||||
one_id numeric(19),
|
||||
constraint pk_migtest_fk_none_via_join primary key (id)
|
||||
);
|
||||
create sequence migtest_fk_none_via_join_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_fk_one (
|
||||
id numeric(19) identity(1,1) not null,
|
||||
id numeric(19) not null,
|
||||
constraint pk_migtest_fk_one primary key (id)
|
||||
);
|
||||
create sequence migtest_fk_one_seq as bigint start with 1 increment by 50;
|
||||
|
||||
|
||||
create table migtest_fk_set_null (
|
||||
id numeric(19) identity(1,1) not null,
|
||||
id numeric(19) not null,
|
||||
one_id numeric(19),
|
||||
constraint pk_migtest_fk_set_null primary key (id)
|
||||
);
|
||||
create sequence migtest_fk_set_null_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_e_basic (
|
||||
id integer identity(1,1) not null,
|
||||
id integer not null,
|
||||
status varchar(1),
|
||||
name varchar(127),
|
||||
description varchar(127),
|
||||
@@ -55,29 +62,34 @@ create table migtest_e_basic (
|
||||
);
|
||||
create unique nonclustered index uq_migtest_e_basic_indextest2 on migtest_e_basic(indextest2) where indextest2 is not null;
|
||||
create unique nonclustered index uq_migtest_e_basic_indextest6 on migtest_e_basic(indextest6) where indextest6 is not null;
|
||||
create sequence migtest_e_basic_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_e_history (
|
||||
id integer identity(1,1) not null,
|
||||
id integer not null,
|
||||
test_string varchar(255),
|
||||
constraint pk_migtest_e_history primary key (id)
|
||||
);
|
||||
create sequence pk_migtest_e_history_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_e_history2 (
|
||||
id integer identity(1,1) not null,
|
||||
id integer not null,
|
||||
test_string varchar(255),
|
||||
constraint pk_migtest_e_history2 primary key (id)
|
||||
);
|
||||
create sequence migtest_e_history2_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_e_ref (
|
||||
id integer identity(1,1) not null,
|
||||
id integer not null,
|
||||
constraint pk_migtest_e_ref primary key (id)
|
||||
);
|
||||
create sequence migtest_e_ref_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create table migtest_e_softdelete (
|
||||
id integer identity(1,1) not null,
|
||||
id integer not null,
|
||||
test_string varchar(255),
|
||||
constraint pk_migtest_e_softdelete primary key (id)
|
||||
);
|
||||
create sequence migtest_e_softdelete_seq as bigint start with 1 increment by 50;
|
||||
|
||||
create index ix_migtest_e_basic_indextest1 on migtest_e_basic (indextest1);
|
||||
create index ix_migtest_e_basic_indextest5 on migtest_e_basic (indextest5);
|
||||
|
||||
Reference in new issue
Block a user