Installed sphinx indexed settings such as:

source = objectsSource path = /home/*****/sphinx/ docinfo = extern mlock = 0 morphology = stem_en, stem_ru, stem_enru, soundex, metaphone blend_chars = -,+,U+20 enable_star=1 html_strip = 1 

We need to find a combination of "z-plaza". In the line I write: search zplaza Finds.

I am connected by mysql the client and I write select * from objectsIndex where match('zplaza');

Does not find! Already I do not know what to set up, help, please!

  • Have you shown a one-to-one request? As if the syntax is: SELECT * FROM comments WHERE MATCH ( field_name ) AGAINST ('zplaza'); // in logical mode, for example: SELECT * FROM comments WHERE MATCH ( field_name ) AGAINST ('+ zplaza' IN BOOLEAN MODE); - Deonis
  • sphinxsearch.com/docs/archives/1.10/sphinxql-select.html Such as you do not have anywhere, tried, swears at the syntax) - Costa

1 answer 1

Most likely your problem is related to the inconsistency of the encodings required and indexed. In the latest versions of Sphinx (for example 2.2.9), it only works with utf8.

I advise you to try to start the mysql client with an explicit indication of the encoding:

 c:\mysql\bin\mysql -h 127.0.0.1 -P 9306 --default-character-set=cp1251 c:\mysql\bin\mysql -h 127.0.0.1 -P 9306 --default-character-set=utf8 

I couldn’t configure mysql access, but everything works perfectly through the PHP API, I use for transcoding:

 iconv("UTF-8", "CP1251", $string); iconv("CP1251", "UTF-8", $string); 

accordingly, good luck.