From 356defabe627d8d393ecc1fa187d7029ba9f1716 Mon Sep 17 00:00:00 2001 From: Fridolin Somers Date: Fri, 22 Dec 2017 15:56:03 +0100 Subject: [PATCH] Bug 8962: Restore Any index behavior and add Anywhere index The "Any" index/register should contains all the data contained in all the other indexes/registers (e.g. Title, Author, Subject, etc). The "Anywhere" index/register should contain the entire record including fields/subfields that aren't indexed anywhere else. In GRS1 indexing the Any index was indeed only on fields defined as indexed. This has changed in DOM where all data in MARC is indexed with Any. This generates a lot of results when no index is defined in search. This patch changes the DOM xsl config generation to add Any to each indexed data and add Anywhere to keep a way of searching on all data. Test plan : - Add a data on a field that is not indexed : for example "toto" in 998$z - Add same data as the title of another record - Index the records - Search on toto without index (uses Any) => you get the 2 records - Search on toto with title index => you get the record with "toto" as title - Apply patch - Update DOM xsl config files - Reindex - Search on toto without index (uses Any) => you get the record with "toto" as title - Search on toto with title index => you get the record with "toto" as title - Search on toto with Anywhere index => you get the 2 records --- etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl b/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl index 59876ca..f11524f 100644 --- a/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl +++ b/etc/zebradb/xsl/koha-indexdefs-to-zebra.xsl @@ -80,7 +80,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + @@ -536,6 +536,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + Any:w Any:p -- 2.7.4