Go Back   CodingForums.com > :: Server side development > MySQL

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 02-06-2013, 12:23 PM   PM User | #1
timgolding
Senior Coder

 
timgolding's Avatar
 
Join Date: Aug 2006
Location: Southampton
Posts: 1,460
Thanks: 89
Thanked 110 Times in 109 Posts
timgolding is on a distinguished road
In boolean mode

Can anyone help me understand why
Code:
SELECT *
FROM `SITES_RANGE`
WHERE MATCH (
NAME
)
AGAINST (
'+sip +compressors'
IN BOOLEAN
MODE
)
returns exactly the same results as

Code:
SELECT *
FROM `SITES_RANGE`
WHERE MATCH (
NAME
)
AGAINST (
'sip compressors'
)
Im using mysql 4.1.
I was hoping that the boolean mode search would only find results with both of the words in the match field. But its returning the same as the simple full text search. What am i doing wrong?
__________________
You can not say you know how to do something, until you can teach it to someone else.
timgolding is offline   Reply With Quote
Old 02-06-2013, 02:36 PM   PM User | #2
timgolding
Senior Coder

 
timgolding's Avatar
 
Join Date: Aug 2006
Location: Southampton
Posts: 1,460
Thanks: 89
Thanked 110 Times in 109 Posts
timgolding is on a distinguished road
After much searching i found the answer.

ft_min_word_len was set to 4 so the term +sip was being ignored as it is under 4 letters.

The solution was

to put
[mysqld]
ft_min_word_len=3

into my.cnf and restart the mysql server then recreate my full text indexes.
__________________
You can not say you know how to do something, until you can teach it to someone else.
timgolding is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 02:24 AM.


Advertisement
Log in to turn off these ads.