From 183851b06bd6c52f3cae5375f433da720d410447 Mon Sep 17 00:00:00 2001
From: Pierre Schmitz <pierre@archlinux.de>
Date: Wed, 11 Oct 2006 18:12:39 +0000
Subject: MediaWiki 1.7.1 wiederhergestellt

---
 maintenance/archives/patch-searchindex.sql | 40 ++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)
 create mode 100644 maintenance/archives/patch-searchindex.sql

(limited to 'maintenance/archives/patch-searchindex.sql')

diff --git a/maintenance/archives/patch-searchindex.sql b/maintenance/archives/patch-searchindex.sql
new file mode 100644
index 00000000..fb54dbbe
--- /dev/null
+++ b/maintenance/archives/patch-searchindex.sql
@@ -0,0 +1,40 @@
+-- Break fulltext search index out to separate table from cur
+-- This is being done mainly to allow us to use InnoDB tables
+-- for the main db while keeping the MyISAM fulltext index for
+-- search.
+
+-- 2002-12-16, 2003-01-25 Brion VIBBER <brion@pobox.com>
+
+-- Creating searchindex table...
+DROP TABLE IF EXISTS /*$wgDBprefix*/searchindex;
+CREATE TABLE /*$wgDBprefix*/searchindex (
+  -- Key to page_id
+  si_page int(8) unsigned NOT NULL,
+  
+  -- Munged version of title
+  si_title varchar(255) NOT NULL default '',
+  
+  -- Munged version of body text
+  si_text mediumtext NOT NULL default '',
+  
+  UNIQUE KEY (si_page)
+
+) TYPE=MyISAM;
+
+-- Copying data into new table...
+INSERT INTO /*$wgDBprefix*/searchindex
+  (si_page,si_title,si_text)
+  SELECT
+    cur_id,cur_ind_title,cur_ind_text
+    FROM /*$wgDBprefix*/cur;
+
+
+-- Creating fulltext index...
+ALTER TABLE /*$wgDBprefix*/searchindex
+  ADD FULLTEXT si_title (si_title),
+  ADD FULLTEXT si_text (si_text);
+
+-- Dropping index columns from cur table.
+ALTER TABLE /*$wgDBprefix*/cur
+  DROP COLUMN cur_ind_title,
+  DROP COLUMN cur_ind_text;
-- 
cgit v1.2.3-54-g00ecf

