Added MarcXchange support.
[yaz-moved-to-github.git] / doc / yaz-marcdump-man.xml
1 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
2 <!-- $Id: yaz-marcdump-man.xml,v 1.4 2005-02-08 13:51:30 adam Exp $ -->
3 <refentry id="yaz-marcdump">
4  <refmeta>
5   <refentrytitle>yaz-marcdump</refentrytitle>
6   <manvolnum>1</manvolnum>
7  </refmeta>
8  
9  <refnamediv>
10   <refname>yaz-marcdump</refname>
11   <refpurpose>MARC record dump utility</refpurpose>
12  </refnamediv>
13  
14  <refsynopsisdiv>
15   <cmdsynopsis>
16    <command>yaz-marcdump</command>
17    <arg choice="opt"><option>-x</option></arg>
18    <arg choice="opt"><option>-X</option></arg>
19    <arg choice="opt"><option>-e</option></arg>
20    <arg choice="opt"><option>-I</option></arg>
21    <arg choice="opt"><option>-O</option></arg>
22    <arg choice="opt"><option>-f <replaceable>from</replaceable></option></arg>
23    <arg choice="opt"><option>-t <replaceable>to</replaceable></option></arg>
24    <arg choice="opt"><option>-v</option></arg>
25    <arg choice="opt"><option>-c <replaceable>cfile</replaceable></option></arg>
26    <arg choice="opt" rep="repeat">file</arg>
27   </cmdsynopsis>
28  </refsynopsisdiv>
29  
30  <refsect1><title>DESCRIPTION</title>
31   <para>
32    <command>yaz-marcdump</command> reads ISO2709/MARC records from one or
33    more files.
34    It validates each record and supports output in line-format, 
35    MARCXML, OAIMARC as well as Hex output.
36   </para>
37   <para>
38    By default, each record is printed to standard output in a line
39    format with newline for each field, $x for each subfield x.
40   </para>
41   <para>
42    <command>yaz-marcdump</command> can also be requested to perform
43    character set conversion of each record.
44   </para>
45  </refsect1>
46  
47  <refsect1><title>OPTIONS</title>
48   
49   <variablelist>
50    <varlistentry>
51     <term>-x</term>
52     <listitem><para>
53       Print MARC records in a simple XML format. 
54       This format is equivalent to YAZ_MARC_SIMPLEXML in
55       <filename>yaz/marcdisp.h</filename>.
56      </para></listitem>
57    </varlistentry>
58
59    <varlistentry>
60     <term>-X</term>
61     <listitem><para>
62       Print MARC records in MARCXML.
63       This format is equivalent to YAZ_MARC_MARCXML in
64       <filename>yaz/marcdisp.h</filename>.
65      </para></listitem>
66    </varlistentry>
67
68    <varlistentry>
69     <term>-X</term>
70     <listitem><para>
71       Print MARC records in MarcXchange format.
72       This format is equivalent to YAZ_MARC_XCHANGE in
73       <filename>yaz/marcdisp.h</filename>.
74      </para></listitem>
75    </varlistentry>
76
77    <varlistentry>
78     <term>-I</term>
79     <listitem><para>
80       Print MARC records in ISO2709 format.
81       This format is equivalent to YAZ_MARC_ISO2709 in
82       <filename>yaz/marcdisp.h</filename>.
83      </para></listitem>
84    </varlistentry>
85
86    <varlistentry>
87     <term>-O</term>
88     <listitem><para>
89       Print MARC records in OAIMARC. Another XML variant.
90       This format is equivalent to YAZ_MARC_OAIMARC in
91       <filename>yaz/marcdisp.h</filename>.
92      </para></listitem>
93    </varlistentry>
94    
95    <varlistentry>
96     <term>-f<replaceable>from</replaceable>]</term>
97     <listitem><para>
98       Specify the character set <replaceable>from</replaceable>
99       of the input MARC record.
100       Should be used in conjunction with option <literal>-t</literal>.
101      </para></listitem>
102    </varlistentry>
103
104    <varlistentry>
105     <term>-t<replaceable>to</replaceable>]</term>
106     <listitem><para>
107       Specify the character set <replaceable>of</replaceable>
108       of the output.
109       Should be used in conjunction with option <literal>-f</literal>.
110      </para></listitem>
111    </varlistentry>
112
113    <varlistentry>
114     <term>-v</term>
115     <listitem><para>
116       Print more information about the parsing process.
117       Useful if you have ill-formatted ISO2709 records as input.
118      </para></listitem>
119    </varlistentry>
120
121   </variablelist>
122  </refsect1>
123
124  <refsect1><title>EXAMPLES</title>
125   <para>
126    The following command converts MARC21/USMARC in MARC-8 encoding to
127    MARC21/USMARC in UTF-8 encoding. (Both input and output is in ISO2709).
128    <screen>
129     yaz-marcdump -f MARC-8 -t UTF-8 -I marc21.raw >marc21.utf8.raw
130    </screen>
131   </para>
132   <para>
133    The same records may be converted to MARCXML instead in UTF-8:
134    <screen>
135     yaz-marcdump -f MARC-8 -t UTF-8 -X marc21.raw >marcxml.xml
136    </screen>
137   </para>
138  </refsect1> 
139
140  <refsect1><title>FILES</title>
141   <para>
142    <filename><replaceable>prefix</replaceable>/bin/yaz-marcdump</filename>
143   </para>
144   <para>
145    <filename><replaceable>prefix</replaceable>/include/yaz/marcdisp.h</filename>
146   </para>
147   </refsect1>
148  <refsect1><title>SEE ALSO</title>
149   <para>
150    yaz(7)
151   </para>
152  </refsect1>
153 </refentry>
154
155 <!-- Keep this comment at the end of the file
156 Local variables:
157 mode: sgml
158 sgml-omittag:t
159 sgml-shorttag:t
160 sgml-minimize-attributes:nil
161 sgml-always-quote-attributes:t
162 sgml-indent-step:1
163 sgml-indent-data:t
164 sgml-parent-document:nil
165 sgml-local-catalogs: nil
166 sgml-namecase-general:t
167 End:
168 -->