diff options
Diffstat (limited to 'upgrades/dbpatches/1.4/mysql/patch/acknowledges.sql')
-rw-r--r-- | upgrades/dbpatches/1.4/mysql/patch/acknowledges.sql | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/upgrades/dbpatches/1.4/mysql/patch/acknowledges.sql b/upgrades/dbpatches/1.4/mysql/patch/acknowledges.sql new file mode 100644 index 00000000..4d9a9b20 --- /dev/null +++ b/upgrades/dbpatches/1.4/mysql/patch/acknowledges.sql @@ -0,0 +1,15 @@ +CREATE TABLE acknowledges_tmp ( + acknowledgeid bigint unsigned DEFAULT '0' NOT NULL, + userid bigint unsigned DEFAULT '0' NOT NULL, + eventid bigint unsigned DEFAULT '0' NOT NULL, + clock integer DEFAULT '0' NOT NULL, + message varchar(255) DEFAULT '' NOT NULL, + PRIMARY KEY (acknowledgeid) +) ENGINE=InnoDB ; +CREATE INDEX acknowledges_1 on acknowledges_tmp (userid); +CREATE INDEX acknowledges_2 on acknowledges_tmp (eventid); +CREATE INDEX acknowledges_3 on acknowledges_tmp (clock); + +insert into acknowledges_tmp select * from acknowledges; +drop table acknowledges; +alter table acknowledges_tmp rename acknowledges; |