koha-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Koha-cvs] koha/misc/migration_tools rebuild_nozebra.pl


From: Antoine Farnault
Subject: [Koha-cvs] koha/misc/migration_tools rebuild_nozebra.pl
Date: Mon, 11 Jun 2007 15:22:59 +0000

CVSROOT:        /sources/koha
Module name:    koha
Changes by:     Antoine Farnault <toins>        07/06/11 15:22:59

Modified files:
        misc/migration_tools: rebuild_nozebra.pl 

Log message:
        next if there is an error getting the biblio.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/koha/misc/migration_tools/rebuild_nozebra.pl?cvsroot=koha&r1=1.5&r2=1.6

Patches:
Index: rebuild_nozebra.pl
===================================================================
RCS file: /sources/koha/koha/misc/migration_tools/rebuild_nozebra.pl,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -b -r1.5 -r1.6
--- rebuild_nozebra.pl  10 May 2007 14:45:15 -0000      1.5
+++ rebuild_nozebra.pl  11 Jun 2007 15:22:59 -0000      1.6
@@ -80,8 +80,14 @@
 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));




reply via email to

[Prev in Thread] Current Thread [Next in Thread]