[Koha] Insert textbook with MySQL stored procedures

Joe Atzberger ohiocore at gmail.com
Thu May 7 03:29:03 NZST 2009


Savitra is right.  You are going to need MARCXML so MarcEdit really is the
best way to go.

Once you have a MARC file you can just use the normal import feature (or the
command line).

-- 
Joe Atzberger
LibLime - Open Source Library Solutions

2009/5/6 savitra sirohi <savitra.sirohi at osslabs.biz>

> Rudy,
>
> Zebra takes data from the marcxml column in biblioitems table. It is best
> to migrate using Marcedit (to create Marc files).
>
> Thanks,
> Savitra Sirohi
> Nucsoft OSS Labs
> http://www.osslabs.biz
>
>
> 2009/5/6 ISM KIS <Ism at kis.in>
>
>>  I have to insert all our textbooks from a textfile.
>>
>> I have created the following stored procedures to do that:
>>
>> CREATE PROCEDURE `InsertBiblio`(IN MyTitle VARCHAR(120), IN MyEdition
>> VARCHAR(120), IN MyAuthor VARCHAR(120), IN MyISBN VARCHAR(120), IN MyYear
>> INTEGER(11), IN MyPublisher VARCHAR(120), IN MyVendor VARCHAR(20), IN
>> MyBugetCategory VARCHAR(120), IN param9 VARCHAR(120), IN param10
>> VARCHAR(120), IN param11 INTEGER(11), IN param12 INTEGER(11), IN param13
>> VARCHAR(120), IN MyCost TEXT, IN param15 VARCHAR(120))
>>     NOT DETERMINISTIC
>>     SQL SECURITY DEFINER
>>     COMMENT ''
>> BEGIN
>>
>> declare MyBiblionumber   integer;
>> declare MyBiblioitemnumber integer;
>>
>> insert into biblio (title,author,copyrightdate,frameworkcode)
>> values(MyTitle,MyAuthor,MyYear,'BKS');
>>
>> set MyBiblionumber =   LAST_INSERT_ID() ;
>>
>> insert into biblioitems (biblionumber,isbn,itemtype)
>> value(MyBiblionumber,MyISBN,'BK');
>> set MyBiblioitemnumber =   LAST_INSERT_ID() ;
>> select MyBiblionumber as Biblionumber, MyBiblioitemnumber as
>> Biblioitemnumber ;
>>
>> END;
>>
>> CREATE PROCEDURE `InsertItem`(IN MyBiblionumber INTEGER(11), IN
>> MyBiblioitemnnumber INTEGER(11), IN MyBarcode VARCHAR(120))
>>     NOT DETERMINISTIC
>>     SQL SECURITY DEFINER
>>     COMMENT ''
>> BEGIN
>> insert into items (biblionumber,biblioitemnumber, barcode, homebranch)
>> values(Mybiblionumber,MyBiblioitemnnumber,Mybarcode,'TextBook');
>> END;
>>
>> But I must miss something because (after rebuild_zebra.pl) I can't find
>> the textbook.
>>
>> *Are there more tables I have to update then (biblio, biblioitems, and
>> items) ?*
>>
>> Rudy Wuthrich
>> Kodaikanal International School
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.katipo.co.nz/pipermail/koha/attachments/20090506/58c5a38e/attachment.htm 


More information about the Koha mailing list