0
我正在嘗試使用Sphinx在其title
列中查找具有words
的行。僅使用SphinxQL查找確切單詞maches
查詢看起來是這樣的:
SELECT * FROM my_table WHERE MATCH ('@title "words"')
但它也返回一個具有行word
(不s
),而不是在標題words
。
我在做什麼錯?
我正在嘗試使用Sphinx在其title
列中查找具有words
的行。僅使用SphinxQL查找確切單詞maches
查詢看起來是這樣的:
SELECT * FROM my_table WHERE MATCH ('@title "words"')
但它也返回一個具有行word
(不s
),而不是在標題words
。
我在做什麼錯?
聽起來像是在索引上啓用morphology
(具體爲詞法?)。
應該考慮啓用index_exact_words
http://sphinxsearch.com/docs/current.html#conf-index-exact-words
它給你確切的形式操作。
MATCH('@title =words')
還爲您提供了有趣expand_keywords
選項:) http://sphinxsearch.com/docs/current.html#conf-expand-keywords
的可能性......或者,如果不要曾經希望這些比賽,可以禁用詞幹:)唉不存在「阻止可選「模式。 (例如模糊操作符來專門幹)
你是對的,非常感謝! –