Commit 160245d5 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

implicit OR search is too brutal.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@38257 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4959faf8
...@@ -50,10 +50,10 @@ class SphinxSEFullTextKey(SearchKey): ...@@ -50,10 +50,10 @@ class SphinxSEFullTextKey(SearchKey):
do multiple fulltext lookups when one would suit the purpose. do multiple fulltext lookups when one would suit the purpose.
Example: Example:
'aaa bbb' : '"aaa" | "bbb"' 'aaa bbb' : '"aaa" "bbb"'
'"aaa bbb"' : '"aaa" | "bbb"' XXX no way to differentiate with the '"aaa bbb"' : '"aaa" "bbb"' XXX no way to differentiate with the
above for now above for now
'"aaa bbb" ccc' : '"aaa bbb" | "ccc"' '"aaa bbb" ccc' : '"aaa bbb" "ccc"'
""" """
column = self.getColumn() column = self.getColumn()
query_list = [] query_list = []
...@@ -63,7 +63,7 @@ class SphinxSEFullTextKey(SearchKey): ...@@ -63,7 +63,7 @@ class SphinxSEFullTextKey(SearchKey):
value_list = value_list[0].split() value_list = value_list[0].split()
append(SimpleQuery(search_key=self, append(SimpleQuery(search_key=self,
comparison_operator=comparison_operator, comparison_operator=comparison_operator,
group=group, **{column:'"%s"' % '" | "'.join(value_list)})) group=group, **{column:'"%s"' % '" "'.join(value_list)}))
return query_list return query_list
verifyClass(ISearchKey, SphinxSEFullTextKey) verifyClass(ISearchKey, SphinxSEFullTextKey)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment