From 271a3958268e998131c7dc553e1c563ea33a83bb Mon Sep 17 00:00:00 2001 From: tipaul Date: Thu, 3 Oct 2002 11:25:39 +0000 Subject: [PATCH] small fixes --- marc/fill_usmarc.pl | 2 ++ marc/updatedb2marc.pl | 6 ++++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/marc/fill_usmarc.pl b/marc/fill_usmarc.pl index ffe9a1a60e..bf6bb38140 100755 --- a/marc/fill_usmarc.pl +++ b/marc/fill_usmarc.pl @@ -33,6 +33,8 @@ my $reqtag=$dbh->prepare("insert into marc_tag_structure (tagfield,liblibrarian, my $reqsubfield=$dbh->prepare("insert into marc_subfield_structure (tagfield,tagsubfield,liblibrarian,repeatable) values (?,?,?,?)"); my $description; foreach $tag (sort keys %$fields) { + $fields->{$tag}->{"name"} =~ s/\(R\)//g; + $fields->{$tag}->{"name"} =~ s/\(NR\)//g; $reqtag->execute($tag,$fields->{$tag}->{"name"},$fields->{$tag}->{"repeating"}); foreach $subfield (sort keys %{$fields->{$tag}->{"subfields"}}) { if ($fields->{$tag}->{"subfields"}->{$subfield}->{"description"}) { diff --git a/marc/updatedb2marc.pl b/marc/updatedb2marc.pl index 1b83dd42ca..7e6ad935f8 100755 --- a/marc/updatedb2marc.pl +++ b/marc/updatedb2marc.pl @@ -22,14 +22,16 @@ package C4::test; use strict; require Exporter; -use C4::Database; +#use C4::Database; use C4::Catalogue; use C4::Biblio; use MARC::Record; use MARC::File::USMARC; +use C4::Context; #die; -my $dbh=&C4Connect; +#my $dbh=&C4Connect; +my $dbh=C4::Context->dbh; $dbh->do("delete from marc_biblio"); $dbh->do("delete from marc_blob_subfield"); $dbh->do("delete from marc_subfield_table"); -- 2.39.5