From f6d65e533c62f6deb21342d4901ece24497b433e Mon Sep 17 00:00:00 2001
From: Pierre Schmitz <pierre@archlinux.de>
Date: Thu, 4 Jun 2015 07:31:04 +0200
Subject: Update to MediaWiki 1.25.1

---
 .../sqlite/archives/patch-drop-page_counter.sql    | 31 ++++++++++++++++++++++
 1 file changed, 31 insertions(+)
 create mode 100644 maintenance/sqlite/archives/patch-drop-page_counter.sql

(limited to 'maintenance/sqlite/archives/patch-drop-page_counter.sql')

diff --git a/maintenance/sqlite/archives/patch-drop-page_counter.sql b/maintenance/sqlite/archives/patch-drop-page_counter.sql
new file mode 100644
index 00000000..ac8151da
--- /dev/null
+++ b/maintenance/sqlite/archives/patch-drop-page_counter.sql
@@ -0,0 +1,31 @@
+-- field is deprecated and no longer updated as of 1.25
+CREATE TABLE /*_*/page_tmp (
+  page_id int unsigned NOT NULL PRIMARY KEY AUTO_INCREMENT,
+  page_namespace int NOT NULL,
+  page_title varchar(255) binary NOT NULL,
+  page_restrictions tinyblob NOT NULL,
+  page_is_redirect tinyint unsigned NOT NULL default 0,
+  page_is_new tinyint unsigned NOT NULL default 0,
+  page_random real unsigned NOT NULL,
+  page_touched binary(14) NOT NULL default '',
+  page_links_updated varbinary(14) NULL default NULL,
+  page_latest int unsigned NOT NULL,
+  page_len int unsigned NOT NULL,
+  page_content_model varbinary(32) DEFAULT NULL,
+  page_lang varbinary(35) DEFAULT NULL
+) /*$wgDBTableOptions*/;
+
+INSERT INTO /*_*/page_tmp
+  SELECT page_id, page_namespace, page_title, page_restrictions, page_is_redirect,
+    page_is_new, page_random, page_touched, page_links_updated, page_latest, page_len,
+    page_content_model, page_lang
+  FROM /*_*/page;
+
+DROP TABLE /*_*/page;
+
+ALTER TABLE /*_*/page_tmp RENAME TO /*_*/page;
+
+CREATE UNIQUE INDEX /*i*/name_title ON /*_*/page (page_namespace,page_title);
+CREATE INDEX /*i*/page_random ON /*_*/page (page_random);
+CREATE INDEX /*i*/page_len ON /*_*/page (page_len);
+CREATE INDEX /*i*/page_redirect_namespace_len ON /*_*/page (page_is_redirect, page_namespace, page_len);
-- 
cgit v1.2.3-54-g00ecf

