Bug 35455: Remove = in ICU for indexing/searching
authorDavid Cook <dcook@prosentient.com.au>
Fri, 1 Dec 2023 02:36:56 +0000 (02:36 +0000)
committerLucas Gass <lucas@bywatersolutions.com>
Thu, 4 Jan 2024 21:00:20 +0000 (21:00 +0000)
commit59cdb045dadf1363e60bc8e136de188426c31205
tree0b7f9b929a91d3fb4848ef7af26797bc69f5879b
parente38316dd1f82c58038a5dddfc94d1b0b409fd623
Bug 35455: Remove = in ICU for indexing/searching

This change more closely aligns ICU and CHR so that ICU also
removes the = character. This fixes issues in ICU when searching
with a : which gets transformed into a =. Without this change,
the Analytics features won't work for titles with a colon in them.

Test plan:
0. Apply the patch and import bibs from Bugzilla (using Staged MARC tools)
1. cp ./etc/zebradb/etc/phrases-icu.xml /etc/koha/zebradb/etc/phrases-icu.xml
2. cp ./etc/zebradb/etc/words-icu.xml /etc/koha/zebradb/etc/words-icu.xml
3. vi /etc/koha/zebradb/etc/default.idx
Change "charmap word-phrase-utf.chr" to "icuchain words-icu.xml" for "index w"
and "icuchain phrases-icu.xml" for "index p"
4. koha-zebra --stop kohadev
5. pkill zebrasrv
6. koha-zebra --start kohadev
7. koha-rebuild-zebra -a -b -f -v kohadev

8. Search for "Awesome title" and open the detail page
9. Note that the "Analytics: Show analytics" line shows up
10. Click that link
11. Note that it opens the "Cool article" record and it displays
"In: Awesome title: awesome subtitle"
12. Click that link
13. Note that it opens the "Awesome title" record

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
(cherry picked from commit 7375d82c408ad6963cf3f3cae060b9376ffca91a)
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
(cherry picked from commit 5035e12440ba7ae576de0eec10d17e20d300eb42)
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
etc/zebradb/etc/phrases-icu.xml
etc/zebradb/etc/words-icu.xml