Convert UNIQUE keys into PRIMARY KEY
[lhc/web/wiklou.git] / maintenance / sqlite / archives / patch-querycache_info-fix-pk.sql
1 CREATE TABLE /*_*/querycache_info_tmp (
2 -- Special page name
3 -- Corresponds to a qc_type value
4 qci_type varbinary(32) NOT NULL default '' PRIMARY KEY,
5
6 -- Timestamp of last update
7 qci_timestamp binary(14) NOT NULL default '19700101000000'
8 ) /*$wgDBTableOptions*/;
9
10 INSERT INTO /*_*/querycache_info_tmp
11 SELECT * FROM /*_*/querycache_info;
12
13 DROP TABLE /*_*/querycache_info;
14
15 ALTER TABLE /*_*/querycache_info_tmp RENAME TO /*_*/querycache_info;