From 6dfb0dca362f5fe75067b80f78932d95740bb82d Mon Sep 17 00:00:00 2001 From: toins Date: Mon, 11 Jun 2007 15:22:59 +0000 Subject: [PATCH] next if there is an error getting the biblio. --- misc/migration_tools/rebuild_nozebra.pl | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/misc/migration_tools/rebuild_nozebra.pl b/misc/migration_tools/rebuild_nozebra.pl index 471b5a5371..ae42c9ea72 100755 --- a/misc/migration_tools/rebuild_nozebra.pl +++ b/misc/migration_tools/rebuild_nozebra.pl @@ -80,8 +80,14 @@ my %result; while (my ($biblionumber) = $sth->fetchrow) { $i++; print "\r$i"; - my $record = GetMarcBiblio($biblionumber); - + my $record; + eval{ + $record = GetMarcBiblio($biblionumber); + }; + if($@){ + print " There was some pb getting biblionumber : ".$biblionumber."\n"; + next; + } # get title of the record (to store the 10 first letters with the index) my ($titletag,$titlesubfield) = GetMarcFromKohaField('biblio.title'); my $title = lc($record->subfield($titletag,$titlesubfield)); -- 2.39.5