X-Git-Url: http://git.equinoxoli.org/?p=migration-tools.git;a=blobdiff_plain;f=extract_holdings;h=619aec14853e961d5fa21aaf7530c1ddc1cb0ef1;hp=f99b08d39de3dd1ccfd18f50056cf1619b2b4592;hb=0f04d792ca52ef7a8c91853046c476b3b5daf37f;hpb=da01404cf73bcf1ddb72992dc5617aab5fefcdd1 diff --git a/extract_holdings b/extract_holdings index f99b08d..619aec1 100755 --- a/extract_holdings +++ b/extract_holdings @@ -92,7 +92,7 @@ sub extract_holdings { for my $value ( @{$rec->{tags}[$holdidx]{multi}{$sub}} ) { my $fh = $MULTIFILE{"$tagid$sub"}; my $clean_value = $value; - $clean_value =~ s/\t//g; + $clean_value =~ s/[\r\n\t]//g; print $fh join("\t", $rec->{egid}, $j, $clean_value), "\n"; } } @@ -143,7 +143,7 @@ sub extract_holdings { for my $value ( @{$rec->{tags}[$tag_idx]{multi}{$sub}} ) { my $fh = $MULTIFILE{"$othertag$sub"}; my $clean_value = $value; - $clean_value =~ s/\t//g; + $clean_value =~ s/[\r\n\t]//g; print $fh normalize_output(join("\t", $rec->{egid}, $j, $clean_value)), "\n"; } }