Helpful Information
 
 
Category: vBulletin Open Source Products
Sphinx: does not index words consisting from national symbols

On my forum after installation Sphinx seem not to index words, that consist from non-latin symbols. My forum is in russian and uses Windows-1251 encoding. Do I need to tune sphinx to do that correctly?

Yes, you need to edit stuff a bit to handle different character encodings. I couldn't say what the exact steps are since I don't use it, but maybe this link would be of some help to you?

http://sphinxsearch.com/faq.html#encoding

It seems, that I was trying to specify global sql_query_pre, while I needed to put in into each "source" section of configuration file. Will try now.

--------------- Added 1273009150 at 1273009150 ---------------

Yea, now it works.

where is the configuration file? can you please explain what did you change in order to fix that?

Each source section should contain SET NAMES query like this:

source DBSource
{
type = mysql

#####################################################################
## SQL settings (for 'mysql' and 'pgsql' types)
#####################################################################

sql_host = " . $vBSphinxSearchConfig->dbservername . "
sql_user = " . $vBSphinxSearchConfig->dbusername . "
sql_pass = " . $vBSphinxSearchConfig->dbpassword . "
sql_db = " . $vBSphinxSearchConfig->dbname . "
sql_port = " . $vBSphinxSearchConfig->dbport . " # optional, default is 3306
sql_query_pre = SET NAMES cp1251
sql_query_pre = SET SESSION query_cache_type=OFF

}










privacy (GDPR)