Re: Converting XML to MARC without reading a file?

2018-04-19 Thread David Cook
I was thinking the same thing because that's what we do in Koha, but I think Andy is getting back more than 1 XML record per HTTP request so I don't think that will work. That said he could use a XML streaming parser and LWP with callbacks and then pass each individual record to new_from_xml. O

Re: Converting XML to MARC without reading a file?

2018-04-19 Thread Dr. Saiful Amin
> ​The function new_from_xml() should work without filehandle I think. I'm > pulling a bunch of MARCXML records from a database and the code looks like > this: > ​My bad. That works only for individual records, not for a batch.​

Re: Converting XML to MARC without reading a file?

2018-04-19 Thread Dr. Saiful Amin
On Thu, Apr 19, 2018 at 5:55 AM, Andy Kohler wrote: > Hi - > > I'm pulling records from the WorldCat Search API in MARCXML, and need to > convert them to binary MARC for further evaluation, which I'll do via > MARC::Record. > > Problem: Converting from MARCXML via MARC::File::XML seems to require