From 317736360b77f74ddbd72f751b33209061238ceb Mon Sep 17 00:00:00 2001 From: Paul POULAIN Date: Tue, 30 Oct 2007 13:02:36 -0500 Subject: [PATCH] fix related #1340 (z3950 search for quick cataloguing) Signed-off-by: Chris Cormack Signed-off-by: Joshua Ferraro --- C4/Breeding.pm | 2 +- cataloguing/z3950_search.pl | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/C4/Breeding.pm b/C4/Breeding.pm index dde6d3c4e5..2669f97fe8 100644 --- a/C4/Breeding.pm +++ b/C4/Breeding.pm @@ -121,7 +121,7 @@ sub ImportBreeding { ($biblioitemnumber) = $searchissn->fetchrow; } } - if ($biblioitemnumber) { + if ($biblioitemnumber && $overwrite_biblio ne 2) { $alreadyindb++; } else { # FIXME - in context of batch load, diff --git a/cataloguing/z3950_search.pl b/cataloguing/z3950_search.pl index 159a1f0b1c..01952a7359 100755 --- a/cataloguing/z3950_search.pl +++ b/cataloguing/z3950_search.pl @@ -61,7 +61,7 @@ my @serverloop = (); my @serverhost; my @breeding_loop = (); -my $DEBUG = 1; # if set to 1, many debug message are send on syslog. +my $DEBUG = 0; # if set to 1, many debug message are send on syslog. unless ($random) { # this var is not useful anymore just kept to keep rel2_2 compatibility @@ -135,11 +135,11 @@ else { $option1->option( 'preferredRecordSyntax', $server->{syntax} ); $oConnection[$s] = create ZOOM::Connection($option1) || $DEBUG - && warn( "something went wrong: " . $oConnection[$s]->errmsg() ); + && warn( "" . $oConnection[$s]->errmsg() ); warn( "server data", $server->{name}, $server->{port} ) if $DEBUG; $oConnection[$s]->connect( $server->{host}, $server->{port} ) || $DEBUG - && warn( "something went wrong: " . $oConnection[$s]->errmsg() ); + && warn( "" . $oConnection[$s]->errmsg() ); $serverhost[$s] = $server->{host}; $encoding[$s] = $server->{syntax}; $s++; @@ -205,7 +205,6 @@ else { $imported, $breedingid ) = ImportBreeding( $marcdata, 2, $serverhost[$k], $encoding[$k], $random, 'z3950' ); - my %row_data; if ( $i % 2 ) { $toggle = "#ffffcc"; -- 2.39.5