[Koha-bugs] [Bug 25900] Double quotes breaks search with Zebra and QueryWeightFields

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Tue Jun 30 15:20:20 CEST 2020


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=25900

--- Comment #1 from Fridolin SOMERS <fridolin.somers at biblibre.com> ---
Created attachment 106432
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=106432&action=edit
Bug 25900: trim spaces in search with Zebra and QueryWeightFields

Search with Zebra and system preference QueryWeightFields on builds a query
with surrounding double quotes : q=tree => q="tree". Therefore existing double
quotes are replaced by a space : q="tree" => q=" tree ".
Looks like the leading space breaks the search, 0 results.
Experimented on Ubuntu Xenial and Bionic with Indexdata repository so Zebra
version is 2.1.4. It might be specific to this version.

Patch corrects by adding trim on operand after transforming quotes into spaces.

Test plan :
1) Use Zebra searchengine and enable system preference QueryWeightFields
2) Go to advanced search
3) Search on title two words you know exists in title surrounded by double
quotes, like "Order of the Phoenix"
4) With patch you get results, no results without patch

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list