Bug 28807

Summary: Item search should search repeated subfields sequentially
Product: Koha Reporter: Andrew Fuerste-Henry <andrewfh>
Component: SearchingAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low    
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:

Description Andrew Fuerste-Henry 2021-08-03 17:30:27 UTC
Say we have a bib with two 650$a tags, "cheese" and "corn." If we set the 650$a up as a searchable field in item search, our search terms will be compared to the string "cheese corn." That means we end up having to wildcard our search terms in both directions to account for the possibility that they might have a term on either side in the record ("%cheese%" and "%corn%").

This would work better if we compared our search term to each value individually, rather than to the concatenated string of all values.
Comment 1 Katrin Fischer 2023-07-01 12:50:26 UTC
I am not sure how we could fix this, the ExtractValue is often not helpful as it gives you no way to define separators for multiple fields that would allow parsing.