From 93593522d82fc89dd3ffc17028f14329c577404a Mon Sep 17 00:00:00 2001 From: Mathieu Saby Date: Sat, 16 Mar 2013 15:35:47 +0100 Subject: [PATCH] Bug 9821: Make indexing of UNIMARC 5XX and 205 more specific 511 field ("false title") is not indexed. 519 field is indexed but does not belong to unimarc standard. Indexing the whole 500/501 make search noisy because of $k (date) and $m (language). $b is useless. Indexing some subfields of 520/530/532/560 could sometimes be harmfull too. In 500/501, $j,$x,$y,$z are subdivisions used of the record is not about a title, but about a subject linked to a title. For example : 500$aBible$xTranslations So they should be indexed in subjects indexes rather than title index. Regarding 205 (edition statement), it is currently indexed in title index. But some subfields of 205 ($f and $g) contain information about the authors of that edition, so only $a,$b,$d should be indexed in title index. An other patch is made for indexing $f $g in author index. This patch does the following changes : 1) Indexing only 205$a,$b,$d in title index 2) Commenting all the 5XX in record.abs 3) Indexing 511 4) Keeping 519 for the moment, but commenting 5) For 500 and 501, indexing subject subfield in subjects index : 500/501$j Subject,Subject:p 500/501$x Subject,Subject:p 500/501$y Subject-name-geographical:w,Subject-name-geographical:p,Subject,Subject:p 500/501$z Subject-chronological:w,Subject-chronological:p,Subject,Subject:p 6) Unindexing the following subfields : 500 and 501 (uniform title) not indexing $b (type of ressource), $k (date), $m (language), $2 (system code),$3 (authority record number) So that 500 $aBible $iNew Testament $mEnglish $qRevised Standard Version $k1972 should be indexed as 500 $aBible $iNew Testament $qRevised Standard Version 520 : preceding title (used for serials) non indexing $j and $x $j is intended for displaying notes. Ex of content : "Issue nos. 1 (summer 1974)-5 (autumn 1975)" $x contains ISSN of former title. Maybe it could be indexed in issn index, but it should not be in Title 530 : key title (used for serials) non indexing $j $j contains volume and date of key title. Could be used if the record contains several 530, to precise the volumes or dates associated with each key title. Nobody will use it in ordinary search. 532 : Developped Title non indexing $z (language of title) 560 : Artificial Title not indexing $5 (code for institution to which the field applies) To test : In a GRS1 environment 1) Create a record with 511$a FalseTitle 205$a Edition $f bz9821 $g bz9821 500$a Bible $b bz9821 $k bz9821 $m bz9821 $j bz9821subject $x bz9821subject $y bz9821subject $z bz9821subject $2 bz9821 $3 bz9821 501$a Bible $b bz9821 $k bz9821 $m bz9821 $j bz9821subject $x bz9821subject $y bz9821subject $z bz9821subject $2 bz9821 $3 bz9821 520$a PTitle $x bz9821 $j bz9821 530$a KTitle $v bz9821 532$a DTitle $z bz9821 560$a DTitle $5 bz9821 2) Apply 3) Rebuild zebra 4) Search in title index : FalseTitle => you should find it 5) Search in title index : bz9821* => you should have no result 6) Search in subject index : bz9821subject => you should have 1 result Do the same in a DOM environment --- .../unimarc/biblios/biblio-koha-indexdefs.xml | 322 +++++++++++--- .../unimarc/biblios/biblio-zebra-indexdefs.xsl | 453 +++++++++++++++----- etc/zebradb/marc_defs/unimarc/biblios/record.abs | 133 +++++- 3 files changed, 718 insertions(+), 190 deletions(-) diff --git a/etc/zebradb/marc_defs/unimarc/biblios/biblio-koha-indexdefs.xml b/etc/zebradb/marc_defs/unimarc/biblios/biblio-koha-indexdefs.xml index ceaba51..5188279 100644 --- a/etc/zebradb/marc_defs/unimarc/biblios/biblio-koha-indexdefs.xml +++ b/etc/zebradb/marc_defs/unimarc/biblios/biblio-koha-indexdefs.xml @@ -428,11 +428,21 @@ Title-cover:w Title-cover:p - - + + + Title:w + Title:p + + + Title:w Title:p - + + + + Title:w + Title:p + Serials:w @@ -1023,26 +1033,199 @@ Host-Item-Number:w - + Koha-Auth-Number:w Koha-Auth-Number:n - + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Subject:w + Subject:p + + + + Subject:w + Subject:p + + + + Subject-name-geographical:w + Subject-name-geographical:p + Subject:w + Subject:p + + + + Subject-chronological:w + Subject-chronological:p + Subject:w + Subject:p + + Koha-Auth-Number:w Koha-Auth-Number:n - + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Subject:w + Subject:p + + + + Subject:w + Subject:p + + + + Subject-name-geographical:w + Subject-name-geographical:p + Subject:w + Subject:p + + + + Subject-chronological:w + Subject-chronological:p + Subject:w + Subject:p + + Koha-Auth-Number:w Koha-Auth-Number:n - - + + Koha-Auth-Number:w Koha-Auth-Number:n + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Koha-Auth-Number:w + Koha-Auth-Number:n + + + + Title:w + Title:p + Koha-Auth-Number:w @@ -1088,21 +1271,61 @@ Koha-Auth-Number:w Koha-Auth-Number:n - + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + + Koha-Auth-Number:w Koha-Auth-Number:n + + + Title:w + Title:p + + + + Title:w + Title:p + + + + Title:w + Title:p + Koha-Auth-Number:w Koha-Auth-Number:n - + Koha-Auth-Number:w Koha-Auth-Number:n + + + Title:w + Title:p + Koha-Auth-Number:w @@ -1118,111 +1341,86 @@ Koha-Auth-Number:w Koha-Auth-Number:n + + + Title:w + Title:p + Koha-Auth-Number:w Koha-Auth-Number:n - - + + Title:w Title:p - - - + + + Title:w Title:p - - + + Title:w Title:p - - - - Title:w - Title:p - + Title:w Title:p - + Title:w Title:p - + Title:w Title:p - + Title:w Title:p - + Title:w Title:p - + Title:w Title:p - + Title:w Title:p - + Title:w Title:p - - - - Title:w - Title:p - - - - Title:w - Title:p - - + + Title:w Title:p - - - - Title:w - Title:p - - + + Title:w Title:p - - + + Title:w Title:p - - - - Title:w - Title:p - - - - Title:w - Title:p - + Koha-Auth-Number:w diff --git a/etc/zebradb/marc_defs/unimarc/biblios/biblio-zebra-indexdefs.xsl b/etc/zebradb/marc_defs/unimarc/biblios/biblio-zebra-indexdefs.xsl index f1e82e3..581d1cf 100644 --- a/etc/zebradb/marc_defs/unimarc/biblios/biblio-zebra-indexdefs.xsl +++ b/etc/zebradb/marc_defs/unimarc/biblios/biblio-zebra-indexdefs.xsl @@ -39,6 +39,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + @@ -631,6 +632,29 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + + + + + + + + + + @@ -1621,6 +1645,118 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1630,6 +1766,76 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1648,6 +1854,57 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1729,6 +1986,34 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -1738,6 +2023,27 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + + + + + + + + @@ -1756,6 +2062,13 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + @@ -1783,6 +2096,13 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + @@ -1792,6 +2112,20 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) + + + + + + + + + + + + + + @@ -2191,19 +2525,6 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - - - - - - - - - - - - @@ -2269,32 +2590,6 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -2308,19 +2603,6 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - - - - - - - - - - - - @@ -2425,32 +2707,6 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -2464,19 +2720,6 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - - - - - - - - - - - - @@ -2503,32 +2746,6 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -2880,7 +3097,7 @@ definition file (probably something like {biblio,authority}-koha-indexdefs.xml) - + diff --git a/etc/zebradb/marc_defs/unimarc/biblios/record.abs b/etc/zebradb/marc_defs/unimarc/biblios/record.abs index 44a5bbe..1fbbb61 100644 --- a/etc/zebradb/marc_defs/unimarc/biblios/record.abs +++ b/etc/zebradb/marc_defs/unimarc/biblios/record.abs @@ -176,8 +176,10 @@ melm 200$e Title:w,Title:p,Title-cover:w,Title-cover:p # part title melm 200$i Title:w,Title:p,Title-cover:w,Title-cover:p -# edition statement -melm 205 Title,Title:p +# edition statement ($f and $g indexed as authors) +melm 205$a Title,Title:p +melm 205$b Title,Title:p +melm 205$d Title,Title:p ########## MATERIAL SPECIFIC AREA ################# # TODO 206 @@ -365,6 +367,7 @@ melm 500$9 Koha-Auth-Number,Koha-Auth-Number:n melm 501$9 Koha-Auth-Number,Koha-Auth-Number:n melm 503$9 Koha-Auth-Number,Koha-Auth-Number:n melm 510$9 Koha-Auth-Number,Koha-Auth-Number:n +melm 511$9 Koha-Auth-Number,Koha-Auth-Number:n melm 512$9 Koha-Auth-Number,Koha-Auth-Number:n melm 513$9 Koha-Auth-Number,Koha-Auth-Number:n melm 514$9 Koha-Auth-Number,Koha-Auth-Number:n @@ -372,6 +375,7 @@ melm 515$9 Koha-Auth-Number,Koha-Auth-Number:n melm 516$9 Koha-Auth-Number,Koha-Auth-Number:n melm 517$9 Koha-Auth-Number,Koha-Auth-Number:n melm 518$9 Koha-Auth-Number,Koha-Auth-Number:n +#FIXME : 519 not in UNIMARC Standard. Keeping it for the moment melm 519$9 Koha-Auth-Number,Koha-Auth-Number:n melm 520$9 Koha-Auth-Number,Koha-Auth-Number:n melm 530$9 Koha-Auth-Number,Koha-Auth-Number:n @@ -382,26 +386,135 @@ melm 541$9 Koha-Auth-Number,Koha-Auth-Number:n melm 545$9 Koha-Auth-Number,Koha-Auth-Number:n melm 560$9 Koha-Auth-Number,Koha-Auth-Number:n -melm 500 Title,Title:p -melm 501 Title,Title:p +# 500 : Uniform title // see Marc21 240 +# indexing $a,$h,$i,$l,$n,$q,$r,$s,$u,$v,$w +# not indexing $b (type of ressource), $k (date), $m (language), $2 (system code),$3 (authority record number) +# indexing as subject $j,$x,$y,$z +melm 500$a Title,Title:p +melm 500$h Title,Title:p +melm 500$i Title,Title:p +melm 500$k Title,Title:p +melm 500$l Title,Title:p +melm 500$n Title,Title:p +melm 500$q Title,Title:p +melm 500$r Title,Title:p +melm 500$s Title,Title:p +melm 500$u Title,Title:p +melm 500$v Title,Title:p +melm 500$w Title,Title:p +melm 500$j Subject,Subject:p +melm 500$x Subject,Subject:p +melm 500$y Subject-name-geographical:w,Subject-name-geographical:p,Subject,Subject:p +melm 500$z Subject-chronological:w,Subject-chronological:p,Subject,Subject:p + +# 501 : Collective uniform title // see Marc21 243 +# indexing $a,$e,$r,$s,$u,$v,$w +# not indexing $b (type of ressource), $k (date), $m (language), $2 (system code),$3 (authority record number) +# indexing as subject $j,$x,$y,$z +melm 501$a Title,Title:p +melm 501$e Title,Title:p +melm 501$r Title,Title:p +melm 501$s Title,Title:p +melm 501$u Title,Title:p +melm 501$w Title,Title:p +melm 501$j Subject,Subject:p +melm 501$x Subject,Subject:p +melm 501$y Subject-name-geographical:w,Subject-name-geographical:p,Subject,Subject:p +melm 501$z Subject-chronological:w,Subject-chronological:p,Subject,Subject:p + +# 503 : Conventional headings : index all the field. ex : $aExposition$eNapoléon$k1er$hempereur des Français$mParis$nGrand-Palais +# indexing all subfields : $a,$b,$d,$e,$f,$g,$h,$i,$j,$k,$l,$m,$n,$o +# FIXME : maybe some subfields are useless melm 503 Title,Title:p -melm 510 Title,Title:p + +# 510 : Parallel Title : title, subtitle, part title // see Marc21 246 #1 +# indexing $a,$e,$h,$i,$j +# not indexing $n (miscellaneous information),$z (language) +melm 510$a Title,Title:p +melm 510$e Title,Title:p +melm 510$h Title,Title:p +melm 510$i Title,Title:p +melm 510$j Title,Title:p + +# 511 : False title +# indexing the only subfield : $a +melm 511$a Title,Title:p + +# 512 : Cover title // see Marc21 246 #4 +# indexing all subfields : $a,$e melm 512 Title,Title:p + +# 513 : Added title page title // see Marc21 246 #5 +# indexing all subfields : $a,$e,$h,$i melm 513 Title,Title:p + +# 514 : Caption Title // see Marc21 246 #6 +# indexing all subfields : $a,$e melm 514 Title,Title:p + +# 515 : Running title // see Marc21 246 #7 +# indexing the only subfield : $a melm 515 Title,Title:p + +# 516 : Spine title // see Marc21 246 #8 +# indexing all subfields : $a,$e melm 516 Title,Title:p + +# 517 : Other variant titles // see Marc21 246 #3 +# indexing all subfields : $a,$e melm 517 Title,Title:p + +# 518 : Modern spelling +# indexing the only subfield : $a melm 518 Title,Title:p + +#FIXME : 519 not in UNIMARC Standard. Keeping it for the moment melm 519 Title,Title:p -melm 520 Title,Title:p -melm 530 Title,Title:p + +# 520 : Preceding Title // see Marc21 247 +# indexing $a,$e,$h,$i +# not indexing $n (miscellaneous information),$j (volumes or dates of former title),$x (ISSN) +melm 520$a Title,Title:p +melm 520$e Title,Title:p +melm 520$h Title,Title:p +melm 520$i Title,Title:p + +# 530 : Key Title // see Marc21 222 +# indexing $a,$b,$v +# not indexing $j (volume or dates associated with key title) +# FIXME $v (volume designation) maybe useless +melm 530$a Title,Title:p +melm 530$b Title,Title:p +melm 530$v Title,Title:p + +# 531 : Abbreviated Title // see Marc21 210 +# indexing all subfields : $a,$b,$v +# FIXME $v (volume designation) maybe useless melm 531 Title,Title:p -melm 532 Title,Title:p + +# 532 : Developped Title +# indexing $a +# not indexing $z (language) +melm 532$a Title,Title:p + +# 540 : Additional Title supplied by the cataloguer +# indexing all subfields : $a,$e,$h,$i melm 540 Title,Title:p + +# 541 : Additional translated Title supplied by the cataloguer // see Marc21 242 +# indexing all subfields : $a,$e,$h,$i melm 541 Title,Title:p -melm 545 Title,Title:p -melm 560 Title,Title:p + +# 545 : Section Title // see Marc21 773 +# indexing the only subfield : $a +melm 545$a Title,Title:p + +# 560 : Artificial Title +# indexing $a,$e +# not indexing $5 (institution to which the field applies) +melm 560$a Title,Title:p +melm 560$e Title,Title:p + ########### SUBJECTS (6xx) ################## melm 600$9 Koha-Auth-Number,Koha-Auth-Number:n -- 1.7.9.5