1 DROP TABLE IF EXISTS /*_*/externallinks_tmp;
3 CREATE TABLE /*$wgDBprefix*/externallinks_tmp (
4 el_id int unsigned NOT NULL PRIMARY KEY AUTO_INCREMENT,
5 el_from int unsigned NOT NULL default 0,
10 INSERT OR IGNORE INTO /*_*/externallinks_tmp (el_from, el_to, el_index) SELECT
11 el_from, el_to, el_index FROM /*_*/externallinks;
13 DROP TABLE /*_*/externallinks;
15 ALTER TABLE /*_*/externallinks_tmp RENAME TO /*_*/externallinks;
17 CREATE INDEX /*i*/el_from ON /*_*/externallinks (el_from, el_to(40));
18 CREATE INDEX /*i*/el_to ON /*_*/externallinks (el_to(60), el_from);
19 CREATE INDEX /*i*/el_index ON /*_*/externallinks (el_index(60));