If you do a 1=21 (ie Subject-heading) Z39.50 search against Koha's authority database, you won't get a result. There's a few reasons for this. If using Zebra: - /etc/koha/zebradb/authorities/etc/bib1.att is missing a line like “att 21 Subject-heading” - /etc/koha/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl isn’t indexing the 150 field into the “Subject-heading” index If using z3950_responder.pl with Elastic, ./etc/z3950/attribute_mappings.yaml doesn't have an appropriate mapping. At a glance, I don't see a subject specific index for subject authorities either in ./admin/searchengine/elasticsearch/mappings.yaml If using z3950_responder.pl with Zebra, then it's the same problem as if you were just using Zebra. -- At the moment, I'm concerned with Zebra, but I'll want to look at Elastic at some point...
Created attachment 163130 [details] [review] Bug 36312: Add Subject-heading 1=21 to Zebra authorities indexing This change adds the 1=21 Subject-heading index to Zebra authorities. Test plan: 0. Apply patch 1. sudo cp etc/zebradb/authorities/etc/bib1.att /etc/koha/zebradb/authorities/etc/bib1.att 2. sudo cp etc/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl \ /etc/koha/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl 3. sudo koha-indexer --stop kohadev 4. sudo koha-zebra --stop kohadev 5. sudo koha-zebra --start kohadev 6. sudo koha-indexer --start kohadev 7. sudo koha-rebuild-zebra -f -a -v kohadev 8. yaz-client unix:/var/run/koha/kohadev/authoritysocket 9. base authorities 10. find @attr 1=21 "Philosophy, Marxist" 11. Zebra returns a hit 12. Celebrate!
Note that this is essential if: 1. You're running Koha as a MARC Authorities Z39.50 target 2. You're searching the above target using Koha's Z39.50 authority search to search for "Subject heading"
Created attachment 163753 [details] [review] Bug 36312: Add Subject-heading 1=21 to Zebra authorities indexing This change adds the 1=21 Subject-heading index to Zebra authorities. Test plan: 0. Apply patch 1. sudo cp etc/zebradb/authorities/etc/bib1.att /etc/koha/zebradb/authorities/etc/bib1.att 2. sudo cp etc/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl \ /etc/koha/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl 3. sudo koha-indexer --stop kohadev 4. sudo koha-zebra --stop kohadev 5. sudo koha-zebra --start kohadev 6. sudo koha-indexer --start kohadev 7. sudo koha-rebuild-zebra -f -a -v kohadev 8. yaz-client unix:/var/run/koha/kohadev/authoritysocket 9. base authorities 10. find @attr 1=21 "Philosophy, Marxist" 11. Zebra returns a hit 12. Celebrate! Signed-off-by: David Nind <david@davidnind.com>
Created attachment 164176 [details] [review] Bug 36312: Add Subject-heading 1=21 to Zebra authorities indexing This change adds the 1=21 Subject-heading index to Zebra authorities. Test plan: 0. Apply patch 1. sudo cp etc/zebradb/authorities/etc/bib1.att /etc/koha/zebradb/authorities/etc/bib1.att 2. sudo cp etc/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl \ /etc/koha/zebradb/marc_defs/marc21/authorities/authority-zebra-indexdefs.xsl 3. sudo koha-indexer --stop kohadev 4. sudo koha-zebra --stop kohadev 5. sudo koha-zebra --start kohadev 6. sudo koha-indexer --start kohadev 7. sudo koha-rebuild-zebra -f -a -v kohadev 8. yaz-client unix:/var/run/koha/kohadev/authoritysocket 9. base authorities 10. find @attr 1=21 "Philosophy, Marxist" 11. Zebra returns a hit 12. Celebrate! Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
This works, just one question, why not use 'Subject-topical' as the 21? It seems to be defined for the same fields, with the exception that Subject heading is in both: <kohaidx:index_subfields tag="150" subfields="abvxyz"> <kohaidx:index_heading tag="150" subfields="abvxyz" subdivisions="vxyz"> But I am not sure the difference between the two, or why we have both Subject-topical and Subject-topical-heading
(In reply to Nick Clemens from comment #5) > This works, just one question, why not use 'Subject-topical' as the 21? It's a good question. Subject-topical is 1079, and Subject-Heading/21 should include more than just topical subjects. But what should it include? Maybe we should be using "Heading". The "Library of Congress Subjects" and "Library of Congress Names" databases seem to index any 1XX heading as "Subject-Heading", since that's what a 6XX bib entry is. -- Then for the Koha Z30.50 authority search points, we could update/expand where we replace "Subject heading" with "Heading (any)" and add a "Subject (topical)". Should probably actually add search points for each of the different 1XX headings.