[Yazlist] YAZ-marcdump utility question

Larry E. Dixson ldix at loc.gov
Fri Jul 28 20:40:26 CEST 2006


Has anyone successfully used the YAZ utility "yaz-marcdump" 
to perform batch conversion of records from MARC-8 to UTF-8
(communication format)?  (We could use a server-based 
utility of this sort.)

FYI, the command syntax follows:

------------------------------------------------------------
$ man yaz-marcdump

YAZ-MARCDUMP(1)                 YAZ-MARCDUMP(1)

NAME
    yaz-marcdump - MARC record dump utility

SYNOPSIS
    yaz-marcdump [-x] [-X] [-e] [-I] [-f from] [-t to] [-v] 
                 [-c cfile] [file...]

DESCRIPTION
     yaz-marcdump reads MARC records from one or more files. It 
     parses each record  and  supports  output  in line-format, 
     ISO2709, MARCXML, MarcX-change as well as Hex output.

     This utility parses records ISO2709(raw MARC) as well as XML
     if that is structured as MARCXML/MarcXchange.

     [ . . . etc. . . . ]

     By default, each record is written to standard output in a 
     line format may be changed with options -X, -e, -I.

     yaz-marcdump can also be requested to perform character set
     conversion of each record.

     [ . . . etc. . . . ]

EXAMPLES
    The following command converts  MARC21/USMARC  in  MARC-8  
    encoding to MARC21/USMARC in UTF-8 encoding. (Both input 
    and output is in ISO2709).

 yaz-marcdump -f MARC-8 -t UTF-8 -Imarc21.raw >marc21.utf8.raw

     [. . . etc. . . .]

--------------------------------------------------------------
--------------------------------------------------------------
$ yaz-marcdump -I test6.raw

    (correctly displays communications records in MARC-8)

$ yaz-marcdump -f marc-8 -t utf-8 -I test6.raw >test7.utf8.raw

    (generates a file of communications records encoded in
     _MARC-8_, not UTF-8)

$ yaz-marcdump -f marc-8 -t utf-8 test6.raw

    (correctly converts and displays UTF-8 records in line
     format)

---------------------------------------------------------

In an older version of YAZ, the command

$ yaz-marcdump -f marc-8 -t utf-8 -I test8.raw >test9.utf8.raw

generates:

Segmentation fault(coredump)

---------------------------------------------------------

If someone has used this utility successfully -- to convert
from MARC-8 to UTF-8 (communcations records, I would welcome
your suggestions. 

Thanks very much.
Larry

------------------------------------------------------------
Larry E. Dixson                    Internet:    ldix at loc.gov
Network Development and MARC
   Standards Office, LA327
Library of Congress                Telephone: (202) 707-5807
Washington, D.C.  20540-4402       Fax:       (202) 707-0115




More information about the Yazlist mailing list