From a6e1f838aeaa5095a05d1c5d65e8122da7ed53aa Mon Sep 17 00:00:00 2001 From: Paul Poulain Date: Tue, 12 Jan 2010 23:47:04 +0100 Subject: [PATCH] bulkmarcimport : removing warnings --- misc/migration_tools/bulkmarcimport.pl | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/misc/migration_tools/bulkmarcimport.pl b/misc/migration_tools/bulkmarcimport.pl index 2e583c87ec..6a8a16b6df 100755 --- a/misc/migration_tools/bulkmarcimport.pl +++ b/misc/migration_tools/bulkmarcimport.pl @@ -21,6 +21,7 @@ use MARC::Charset; use C4::Context; use C4::Biblio; use C4::Koha; +use C4::Debug; use C4::Charset; use C4::Items; use Unicode::Normalize; @@ -267,16 +268,16 @@ RECORD: while ( ) { my $server=($authorities?'authorityserver':'biblioserver'); my ($error, $results,$totalhits)=C4::Search::SimpleSearch( $query, 0, 3, [$server] ); die "unable to search the database for duplicates : $error" if (defined $error); - warn "$query $server : $totalhits"; + #warn "$query $server : $totalhits"; if ($results && scalar(@$results)==1){ my $marcrecord = MARC::File::USMARC::decode($results->[0]); $id=GetRecordId($marcrecord,$tagid,$subfieldid); } elsif ($results && scalar(@$results)>1){ - warn "more than one match for $query"; + $debug && warn "more than one match for $query"; } else { - warn "nomatch for $query"; + $debug && warn "nomatch for $query"; } } my $originalid; -- 2.39.5