/ Published in: PHP
Expand |
Embed | Plain Text
$mdb2->exec('CREATE TABLE temp_table as SELECT * FROM hatebu_hotentries GROUP BY link;'); $mdb2->exec('DROP TABLE hatebu_hotentries;'); $mdb2->exec('ALTER TABLE temp_table RENAME TO hatebu_hotentries;'); $mdb2->exec('ALTER TABLE hatebu_hotentries ADD PRIMARY KEY(id);'); $mdb2->exec('ALTER TABLE hatebu_hotentries ADD INDEX ( id );'); $mdb2->exec('ALTER TABLE hatebu_hotentries CHANGE id id INT NOT NULL AUTO_INCREMENT;');
You need to login to post a comment.
