Sublime directory Surf the web anonymous Pagerank Monitor


min word length with fulletext search

olaf
Wed 3 October 2007, 11:28 pm GMT +0300
Hi,

I need to use the full text search feature on some reseller machine. Now I need to lower the value for the minimun string length in searches:

from the manual:
Quote
The minimum and maximum lengths of words to be indexed are defined by the ft_min_word_len and ft_max_word_len system variables. (See Section 5.2.3, “System Variables”.) The default minimum value is four characters; the default maximum is version dependent. If you change either value, you must rebuild your FULLTEXT indexes. For example, if you want three-character words to be searchable, you can set the ft_min_word_len variable by putting the following lines in an option file:

[mysqld]
ft_min_word_len=3


what does they mean with "putting the following lines in an option file:"

where and how to place an option file?

Nikolas
Wed 3 October 2007, 11:33 pm GMT +0300
The option file is the my.cnf. As this is a reseller machine and you don't have root access, you can try to execute this query:

Quote
SET GLOBAL ft_min_word_len=3

olaf
Thu 4 October 2007, 09:30 am GMT +0300
Thanks,

will say I have to use this query before every search query?

olaf
Thu 4 October 2007, 10:32 am GMT +0300
no success...

Quote
Error

SQL query:

SET GLOBAL ft_min_word_len =3

MySQL said: Documentation
#1193 - Unknown system variable 'ft_min_word_len'

Nikolas
Thu 4 October 2007, 11:59 am GMT +0300
The query I gave you is to set the variable, and yes - if it worked - you should use it whenever you start a connection.

Now this is not working because your host maybe has a lower version of mysql?

olaf
Thu 4 October 2007, 12:00 pm GMT +0300

Now this is not working because your host maybe has a lower version of mysql?

no, I use mysql5

Nikolas
Thu 4 October 2007, 12:09 pm GMT +0300
I am not sure about this. Maybe only the root user has rights to play with these variables.

Have you contact your host?

olaf
Thu 4 October 2007, 12:12 pm GMT +0300
I am not sure about this. Maybe only the root user has rights to play with these variables.

Have you contact your host?

yes I send them an email yesterday, I think they need to place an option file for one of my db users or I need to take a VPS (is a VPS good for fulltext searches in a table with 1.5mio records?)

Nikolas
Thu 4 October 2007, 12:21 pm GMT +0300
No VPS wont be good for that :)

olaf
Thu 4 October 2007, 12:25 pm GMT +0300
No VPS wont be good for that :)
I need a server with more memory right?

Nikolas
Fri 5 October 2007, 12:33 pm GMT +0300
I think full text search requires both memory and processing capabilities.

Of course you can use some way to cache results and this will help you use less resources.

Archive for SMF v1.00 by N.P. Valid XHTML 1.0 Transitional