JBAS-980 auth-to-auth uses correct leader position
authorBill Erickson <berickxx@gmail.com>
Wed, 18 Nov 2015 16:01:58 +0000 (11:01 -0500)
committerBill Erickson <berickxx@gmail.com>
Thu, 21 Mar 2019 19:46:23 +0000 (15:46 -0400)
008 indexes are zero-based.  We want index 11, not 10.

Signed-off-by: Bill Erickson <berickxx@gmail.com>
KCLS/linking/authority_authority_linker.pl

index 326e216..e190016 100755 (executable)
@@ -157,7 +157,7 @@ while (my ($src, $links) = $sth->fetchrow_array) {
         my $src_rec = $e->retrieve_authority_record_entry($src) or
             die $e->die_event;
         my $src_marc = MARC::Record->new_from_xml($src_rec->marc);
-        my $Auth_Source_Indic = substr($src_marc->field('008')->data(), 10, 1);
+        my $Auth_Source_Indic = substr($src_marc->field('008')->data(), 11, 1);
 
         for my $link (split ';', $links) {
             my ($target, $field_id) = split ',', $link;
@@ -168,7 +168,7 @@ while (my ($src, $links) = $sth->fetchrow_array) {
                     die $e->die_event;
             my $target_marc = MARC::Record->new_from_xml($target_rec->marc);
             my $cni = $target_marc->field('003')->data;
-            my $Auth_Target_Indic = substr($target_marc->field('008')->data(), 10, 1);
+            my $Auth_Target_Indic = substr($target_marc->field('008')->data(), 11, 1);
             my $acsaf = get_acsaf($e, $field_id) or die $e->die_event;
 
             for my $field ($src_marc->field($acsaf->tag)) {