MySQL Forums
Forum List  »  Full-Text Search

Fulltextsearch + not working as expected
Posted by: Thomas Kernstock
Date: December 14, 2017 04:43AM

Hi,

I try to test MySQL Fulltextsearch compared to SOLR. I set up an InnoDB table with an int-key and a longtext field including a fulltextindex.

CREATE TABLE cvtext ( id int(11) NOT NULL AUTO_INCREMENT, cvtext longtext NOT NULL, PRIMARY KEY (id), FULLTEXT KEY cvtext (cvtext) ) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8;

By the way - I'm using MySQL 4.6.16 and ft_min_word_len=3.

My question is regarding the boolean search:

1) select * from cvtext where MATCH(cvtext) AGAINST('+SQL') => results in:

2 oracle SQL database developer
1 oracle SQL database entwickler
3 oracle SQL database
5 oracle SQL datenbank developer entwickler

2) select * from cvtext where MATCH(cvtext) AGAINST('+SQL +oracle') => results in:

2 oracle SQL database developer
1 oracle SQL database entwickler
3 oracle SQL database
5 oracle SQL datenbank developer entwickler
4 oracle datawarehouse developer entwickler

So the first query is i.m.h.o. correct and returns only records with SQL included. The second query should do the same since I use '+' but it also returns record no 4. which doesn't contain SQL.

Any ideas what could be wrong or did I not understand the query logic?

Options: ReplyQuote


Subject
Views
Written By
Posted
Fulltextsearch + not working as expected
193
December 14, 2017 04:43AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.