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

Nick Clemens (kidclamp) <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #171497|0                           |1
        is obsolete|                            |

--- Comment #7 from Nick Clemens (kidclamp) <[email protected]> ---
Created attachment 172165
  -->
https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=172165&action=edit
Bug 37871: Remove extraneous 246 subfields from the title mappings
(Elasticsearch, MARC21)

This patch limits indexing of field 246 to $a, $b, $n, and $p in
various title indexes.
Previously, all 246 subfields were indexed, including non-title
subfields such as $i (Display text), $g (Miscellaneous information),
and linking subfields, making the title index very large and giving
false results.

To test:

1. Add all the 246 subfields to the default bibliographic framework
   1.1. Go to Administration > MARC bibliographic framework
   1.2. Click Actions > MARC structure next to the Default framework
   1.3. Search for 246
   1.4. Click Actions > Edit subfields
   1.5. For each subfield, make sure Editor is checked
   1.6. Click Save changes

2. Create a new record and fill out all the 246 subfields
   2.1. Go to Cataloging
   2.2. Click New record
   2.3. Fill out the mandatory fields (000, 003, 005, 008, 040$c,
        245$a, 942$c)
   2.4. Fill out all the subfields in 246 (I simply write the name of
        the subfield in the text field e.g. Display text in 246$i)
   2.5. Click Save
   2.6. Click Normal to access the detailed record

3. View the Elastic search record
   --> All the subfields (including "Display text", "Miscellaneous
       information" and other non-title subfields) should be indexed in
       - title
       - title__suggestion
       - title-abbreviated
       - title-abbreviated__sort
       - title expanded
       - title-expanded__sort
       - title-former
       - title-former__sort

4. Make a title or keyword search for "Display" (or whatever you wrote
   in 246$i)
   --> Your record should be in the results

5. Apply patch

6. Rebuild the index using -r

koha-elasticsearch --rebuild -d -r -v kohadev

7. Redo step 3
   --> Only 246 $a, $b, $n, and $p should be indexed

8. Redo step 4
   --> Your record should NOT be in the results

Signed-off-by: Phil Ringnalda <[email protected]>
Signed-off-by: Nick Clemens <[email protected]>

-- 
You are receiving this mail because:
You are watching all bug changes.
_______________________________________________
Koha-bugs mailing list
[email protected]
https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs
website : http://www.koha-community.org/
git : http://git.koha-community.org/
bugs : http://bugs.koha-community.org/

Reply via email to