http://www.mediawiki.org/wiki/Special:Code/MediaWiki/89824
Revision: 89824
Author: tstarling
Date: 2011-06-10 12:59:07 +0000 (Fri, 10 Jun 2011)
Log Message:
-----------
Fixed complete breakage of editing in PG, including the default main page which
was missing, by doing a partial backport of r81439 to get the to_tsvector()
calling convention update.
Modified Paths:
--------------
branches/REL1_17/phase3/RELEASE-NOTES
branches/REL1_17/phase3/maintenance/postgres/tables.sql
Modified: branches/REL1_17/phase3/RELEASE-NOTES
===================================================================
--- branches/REL1_17/phase3/RELEASE-NOTES 2011-06-10 12:16:15 UTC (rev
89823)
+++ branches/REL1_17/phase3/RELEASE-NOTES 2011-06-10 12:59:07 UTC (rev
89824)
@@ -87,6 +87,8 @@
any necessary database tables.
* (bug 28983) Fixed automated installation of extensions that overwrite $path.
* Fixed error caused by missing magic words.
+* Fixed breakage of article editing in PostgreSQL due to text search
+ configuration errors.
=== Configuration changes in 1.17 ===
Modified: branches/REL1_17/phase3/maintenance/postgres/tables.sql
===================================================================
--- branches/REL1_17/phase3/maintenance/postgres/tables.sql 2011-06-10
12:16:15 UTC (rev 89823)
+++ branches/REL1_17/phase3/maintenance/postgres/tables.sql 2011-06-10
12:59:07 UTC (rev 89824)
@@ -495,7 +495,7 @@
CREATE INDEX job_cmd_namespace_title ON job (job_cmd, job_namespace,
job_title);
-- Tsearch2 2 stuff. Will fail if we don't have proper access to the tsearch2
tables
--- Note: if version 8.3 or higher, we remove the 'default' arg
+-- Version 8.3 or higher only. Previous versions would need another parmeter
for to_tsvector.
-- Make sure you also change patch-tsearch2funcs.sql if the funcs below change.
ALTER TABLE page ADD titlevector tsvector;
@@ -503,9 +503,9 @@
$mw$
BEGIN
IF TG_OP = 'INSERT' THEN
- NEW.titlevector = to_tsvector('default',REPLACE(NEW.page_title,'/',' '));
+ NEW.titlevector = to_tsvector(REPLACE(NEW.page_title,'/',' '));
ELSIF NEW.page_title != OLD.page_title THEN
- NEW.titlevector := to_tsvector('default',REPLACE(NEW.page_title,'/',' '));
+ NEW.titlevector := to_tsvector(REPLACE(NEW.page_title,'/',' '));
END IF;
RETURN NEW;
END;
@@ -520,9 +520,9 @@
$mw$
BEGIN
IF TG_OP = 'INSERT' THEN
- NEW.textvector = to_tsvector('default',NEW.old_text);
+ NEW.textvector = to_tsvector(NEW.old_text);
ELSIF NEW.old_text != OLD.old_text THEN
- NEW.textvector := to_tsvector('default',NEW.old_text);
+ NEW.textvector := to_tsvector(NEW.old_text);
END IF;
RETURN NEW;
END;
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs