From b4d54d09eed966d8420eb4a945f2a6f16bac23c1 Mon Sep 17 00:00:00 2001 From: Ian Docherty Date: Tue, 11 Dec 2012 12:02:52 -0500 Subject: [PATCH] Added sql to create the schema --- var/upgrades/4.0000.sql | 45 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 var/upgrades/4.0000.sql diff --git a/var/upgrades/4.0000.sql b/var/upgrades/4.0000.sql new file mode 100644 index 00000000..79526bdc --- /dev/null +++ b/var/upgrades/4.0000.sql @@ -0,0 +1,45 @@ + +create table fleet ( + id int(11) not null auto_increment, + body_id int(11) not null, + shipyard_id int(11) not null, + date_started datetime not null, + date_available datetime not null, + mark varchar(10) not null, + type varchar(30) not null, + task varchar(30) not null, + name varchar(30) not null, + speed int(11) not null, + stealth int(11) not null, + combat int(11) not null, + hold_size int(11) not null, + payload mediumblob, + roundtrip tinyint(4) not null default 0, + direction varchar(3) not null, + foreign_body_id int(11), + foreign_star_id int(11), + berth_level tinyint(4) default 1, + quantity int(11) not null default 1, + primary key (id), + key f_mark (mark), + key f_idx_body_id (body_id), + key f_idx_foreign_body_id (foreign_body_id), + key f_idx_foreign_star_id (foreign_star_id), + constraint wc_f_body_id foreign key (body_id) references body (id), + constraint wc_f_foreign_body_id foreign key (foreign_body_id) references body (id), + constraint wc_f_foreign_star_id foreign key (foreign_star_id) references star (id) +); + +create table schedule ( + id int(11) not null auto_increment, + queue varchar(30) not null, + job_id int(11) not null default 0, + delivery datetime not null, + priority int(11) not null default 0, + parent_table varchar(30) not null, + parent_id int(11) not null, + task varchar(30) not null, + args mediumblob, + primary key (id) +); + -- 2.51.2