From 6ed8377b0ed321cf0e60ad264bb408a7933990bf Mon Sep 17 00:00:00 2001 From: Nick Liu Date: Sat, 4 Jan 2025 15:40:14 +0100 Subject: [PATCH] #5209: Add full-text indexes to table `comments` `e107_handlers/search/search_comment.php` hasn't been migrated to e107 v2 standards yet, so we forgot to add indexes of the search fields specified here: https://github.com/e107inc/e107/blob/a3c04d6b1dcf5593462863bd4a80c5f2d809f2f1/e107_handlers/search/search_comment.php#L67 --- e107_core/sql/core_sql.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/e107_core/sql/core_sql.php b/e107_core/sql/core_sql.php index d577efec6..7c8cfe223 100755 --- a/e107_core/sql/core_sql.php +++ b/e107_core/sql/core_sql.php @@ -103,7 +103,9 @@ CREATE TABLE comments ( comment_share tinyint(1) unsigned NOT NULL default '0', PRIMARY KEY (comment_id), KEY comment_blocked (comment_blocked), - KEY comment_author_id (comment_author_id) + KEY comment_author_id (comment_author_id), + FULLTEXT (comment_comment), + FULLTEXT (comment_author_name) ) ENGINE=InnoDB; # --------------------------------------------------------