diff options
Diffstat (limited to 'upgrades/dbpatches/1.3/postgresql/patch/mappings.sql')
-rw-r--r-- | upgrades/dbpatches/1.3/postgresql/patch/mappings.sql | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/upgrades/dbpatches/1.3/postgresql/patch/mappings.sql b/upgrades/dbpatches/1.3/postgresql/patch/mappings.sql new file mode 100644 index 00000000..afeb59ac --- /dev/null +++ b/upgrades/dbpatches/1.3/postgresql/patch/mappings.sql @@ -0,0 +1,12 @@ +CREATE TABLE mappings_tmp ( + mappingid bigint unsigned DEFAULT '0' NOT NULL, + valuemapid bigint unsigned DEFAULT '0' NOT NULL, + value varchar(64) DEFAULT '' NOT NULL, + newvalue varchar(64) DEFAULT '' NOT NULL, + PRIMARY KEY (mappingid) +) ENGINE=InnoDB; +CREATE INDEX mappings_1 on mappings_tmp (valuemapid); + +insert into mappings_tmp select * from mappings; +drop table mappings; +alter table mappings_tmp rename mappings; |