From 83182bda24af3b7e755eb0dd2c877ec17e1ab411 Mon Sep 17 00:00:00 2001 From: jordan Date: Wed, 1 Jun 2011 11:24:01 +0000 Subject: [PATCH] adding an update that creates full text search indexes for the mysqlfulltext module git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@1055 0cfe37f9-358a-4d5e-be75-b63607b5c754 --- forum_modules/mysqlfulltext/fts_install.sql | 9 ++++++++- forum_modules/mysqlfulltext/fts_update.sql | 8 ++++++++ forum_modules/mysqlfulltext/startup.py | 2 +- 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/forum_modules/mysqlfulltext/fts_install.sql b/forum_modules/mysqlfulltext/fts_install.sql index c32bc31..ae67cc0 100644 --- a/forum_modules/mysqlfulltext/fts_install.sql +++ b/forum_modules/mysqlfulltext/fts_install.sql @@ -30,4 +30,11 @@ CREATE TRIGGER fts_on_update AFTER UPDATE ON forum_node | -INSERT INTO forum_mysqlftsindex (node_id, title, body, tagnames) SELECT id, UPPER(title), UPPER(body), UPPER(tagnames) FROM forum_node; \ No newline at end of file +INSERT INTO forum_mysqlftsindex (node_id, title, body, tagnames) SELECT id, UPPER(title), UPPER(body), UPPER(tagnames) FROM forum_node; +| + +delimiter | + +ALTER TABLE forum_mysqlftsindex ADD FULLTEXT(body); +ALTER TABLE forum_mysqlftsindex ADD FULLTEXT(title); +ALTER TABLE forum_mysqlftsindex ADD FULLTEXT(tagnames); diff --git a/forum_modules/mysqlfulltext/fts_update.sql b/forum_modules/mysqlfulltext/fts_update.sql index a95c827..2582554 100644 --- a/forum_modules/mysqlfulltext/fts_update.sql +++ b/forum_modules/mysqlfulltext/fts_update.sql @@ -24,3 +24,11 @@ CREATE TRIGGER fts_on_update AFTER UPDATE ON forum_node END; | + +delimiter | + +ALTER TABLE forum_mysqlftsindex ADD FULLTEXT(body); +ALTER TABLE forum_mysqlftsindex ADD FULLTEXT(title); +ALTER TABLE forum_mysqlftsindex ADD FULLTEXT(tagnames); + +| \ No newline at end of file diff --git a/forum_modules/mysqlfulltext/startup.py b/forum_modules/mysqlfulltext/startup.py index 232bbb4..387019a 100644 --- a/forum_modules/mysqlfulltext/startup.py +++ b/forum_modules/mysqlfulltext/startup.py @@ -8,7 +8,7 @@ from forum.models.question import Question, QuestionManager from forum.models.node import Node from forum.modules import decorate -VERSION = 2 +VERSION = 3 f_name = None -- 2.39.5