[Koha] Something new with bulkmarcimport.pl
Andro Gagne
apgagne at rochester.rr.com
Fri Jan 6 17:24:06 NZDT 2006
Stephen,
At 07:53 PM 1/5/06 -0500, you wrote:
>Andro, I've forgotten what Koha version you are using.
I'm not at the museum as I write this. If I remember correctly,
I'm using ver. 2.2.2.
> The Biblio.pm line
>numbers you list don't match my (2.2.4) Biblio.pm.
>
>In any case, I would guess that you have some MARC records in the file
>that have errors.
That's what I was thinking at first, of course. It looked like I
was getting a steady stream of messages saying "DBD::mysql::db do failed:
Access denied for user: 'myuserid at localhost' to
database 'libcat' at /usr/local/koha/intranet/modules/C4/Biblio.pm line
331. [or 426.]" on the screen. It looked like there were hundreds of lines
of these messages--so many that I could not scroll back to the first
one. But when I searched for records, I found that there were quite a few
records in the database. And this was the first time I had attempted
importing MARC records. To confuse matters more, the last line of the
script's output, "1572 MARC record done in 731.838590145111 seconds," made
me wonder whether the script was telling me 1,572 records had been imported
successfully or just telling me that 1,572 records had been processed,
giving me no information about successful imports. As this first import of
records was done without mapping item information in the MARC records to
the Koha database's item field, I could not get a report of the number of
items in the OPAC. I'm hoping I can use bulkmarcimport.pl to delete all of
the current records in the OPAC database so I can properly map the item
information tag(s) and re-import the records. If I remember correctly,
bulkmarcimport.pl has a switch that will allow me to delete the records in
the OPAC. If you have any advice for me on this point, I'd be very pleased
to hear it.
> There is another script in the intranet/scripts/misc
>directory called dumpmarc.pl that will simply list out your MARC file. But
>with 1500+ records, it wouldn't be much fun looking for stray errors!
I am familiar with it, as I used it to look over a number of
records to make sure they looked like they were in good shape before trying
to import them. However, as you can imagine, I did not examine all 1,572
of them. To resolve my issue with bulkmarcimport.pl, what I may need to do
is to get a batch of only 10 records in a file, examine them in
dumpmarc.pl, and then import them with bulkmarcimport.pl. If I get the
same kind of screen output from bulkmarcimport.pl with those records, I
will have a much more manageable situation to deal with.
>You could also use this script to find the title of the last record in the
>file. Do a search on that title and the Biblionumber on the screen should
>equal the number of records in your catalog -- assuming you haven't yet
>been doing any deleting of records.
That's a very good suggestion, as I haven't deleted any of the
imported records. Thanks.
Best regards,
Andro P. Gagné
P.O. Box 715
Canandaigua, NY 14424
More information about the Koha
mailing list