2 $Id: yaz-client-commands.xml,v 1.6 2004-12-09 09:30:00 adam Exp $
3 Commands for YAZ client.
4 Included in both manual and man page for yaz-client.
8 <literal>open </literal><replaceable>zurl</replaceable>
11 <para>Opens a connection to a server. The syntax for
12 <replaceable>zurl</replaceable> is the same as described
13 above for connecting from the command line.
19 [<literal>(tcp|ssl|unix|http)':'</literal>]<replaceable>host</replaceable>
20 [:<replaceable>port</replaceable>][/<replaceable>base</replaceable>]
25 <literal>quit</literal>
28 <para>Quits YAZ client</para>
32 <literal>f </literal><replaceable>query</replaceable></term>
34 <para>Sends a Search Request using the <replaceable>query</replaceable>
40 <literal>delete</literal> <replaceable>setname</replaceable></term>
42 <para>Deletes result set with name <replaceable>setname</replaceable>
47 <literal>base </literal><replaceable>base1</replaceable>
48 <replaceable>base2</replaceable> ...
51 <para>Sets the name(s) of the database(s) to search. One or more
52 databases may be specified separated by blanks. This commands overrides
53 the database given in <replaceable>zurl</replaceable>.
58 <literal>show </literal>
59 [<replaceable>start</replaceable>[+<replaceable>number</replaceable>]]
62 <para>Fetches records by sending a Present Request from the start
64 <replaceable>start</replaceable>
65 a number of records given by <replaceable>number</replaceable>. If
66 <replaceable>start</replaceable> is not given, then the client
67 will fetch from position of the last retrieved record plus 1. If
68 <replaceable>number</replaceable> is not given, then one record will
74 <literal>scan</literal> <replaceable>term</replaceable>
78 database index for a term. The syntax resembles the syntax
79 for <literal>find</literal>.
80 If you want to scan for the word <literal>water</literal> you could
87 but if you want to scan only in, say the title field, you would write
95 <literal>scanpos</literal> <replaceable>pos</replaceable>
99 Sets preferred position for scan. This value
100 is used in next scan. By default position is 1.
105 <literal>scanstep</literal> <replaceable>step</replaceable>
109 Set step-size for scan. This value is used in next scan
110 sent to the target. By default step-size is 0.
114 <varlistentry id="sortspec"><term>
115 <literal>sort</literal> <replaceable>sortspecs</replaceable>
118 <para>Sorts a result set. The sort command takes a
119 sequence of sort specifications. A sort
120 specification holds a field (sort criteria) and is followed by flags.
121 If the sort criteria includes <literal>=</literal> it is assumed
122 that the sort SortKey is of type sortAttributes using Bib-1.
123 The integer before <literal>=</literal> is
124 the attribute type and the integer following <literal>=</literal>
125 is the attribute value.
126 If no <literal>=</literal> is in the SortKey it is treated as a
127 sortfield-type of type InternationalString.
128 Flags observed are: <literal>s</literal>
129 for case sensitive, <literal>i</literal> for case insensitive,
130 <literal><</literal> for sort ascending and <literal>></literal>
136 <literal>sort+</literal>
139 <para>Same as <literal>sort</literal> but stores the sorted
140 result set in a new result set.
145 <literal>authentication</literal> <replaceable>openauth</replaceable>
148 <para>Sets up a authentication string if a server requires
149 authentication (v2 OpenStyle). The authentication string is first
150 sent to the server when the <literal>open</literal> command is
151 issued and the Z39.50 Initialize Request is sent, so this command
152 must be used before <literal>open</literal> in order to be effective.
153 A common convention for the <replaceable>authopen</replaceable> string
154 is that the username - and password is separated by a slash, e.g.
155 <literal>myusername/mysecret</literal>.
161 <literal>list_all</literal>
164 <para>This command displays status and values for many settings.
170 <literal>lslb</literal> <replaceable>n</replaceable>
173 <para>Sets the limit for when no records should be returned
174 together with the search result.
177 url="http://lcweb.loc.gov/z3950/agency/markup/04.html#3.2.2.1.6">
186 <literal>ssub</literal> <replaceable>n</replaceable>
189 <para>Sets the limit for when all records should be returned with
193 url="http://lcweb.loc.gov/z3950/agency/markup/04.html#3.2.2.1.6">
195 </ulink> for more details.
201 <literal>mspn</literal> <replaceable>n</replaceable>
204 <para>Sets the number of records should be returned if the
205 number of records in the result set is between the values of
206 <literal>lslb</literal> and <literal>ssub</literal>.
209 url="http://lcweb.loc.gov/z3950/agency/markup/04.html#3.2.2.1.6">
217 <literal>status</literal>
220 <para>Displays the values of <literal>lslb</literal>,
221 <literal>ssub</literal> and <literal>mspn</literal>.
226 <literal>setname</literal>
229 <para>Switches named result sets on and off. Default is on.
234 <literal>cancel</literal>
237 <para>Sends a Trigger Resource Control Request to the target.
242 <literal>format</literal> <replaceable>oid</replaceable>
245 <para>Sets the preferred transfer syntax for retrieved records.
246 yaz-client supports all the record syntaxes that currently
249 url="http://lcweb.loc.gov/z3950/agency/defns/oids.html#5">
252 for more details. Commonly used records syntaxes include usmarc,
258 <literal>elements</literal> <replaceable>e</replaceable>
261 <para>Sets the element set name for the records. Many targets support
262 element sets are B (for brief) and F (for full).
267 <literal>close</literal>
270 <para>Sends a Z39.50 Close APDU and closes connection with the peer
275 <literal>querytype</literal> <replaceable>type</replaceable>
278 <para>Sets the query type as used by command <literal>find</literal>.
279 The following is supported:
280 <literal>prefix</literal> for
281 <link linkend="PQF">Prefix Query Notation</link> (Type-1 Query);
282 <literal>ccl</literal> for CCL search (Type-2 Query),
283 <literal>cql</literal> for CQL (Type-104 search with CQL OID),
284 <literal>ccl2rpn</literal> for
285 <link linkend="CCL">CCL</link> to RPN conversion (Type-1 Query).
286 <literal>cql2rpn</literal> for
287 CQL to RPN conversion (Type-1 Query).
292 <literal>attributeset</literal> <replaceable>set</replaceable>
296 Sets attribute set OID for prefix queries (RPN, Type-1).
301 <literal>refid</literal> <replaceable>id</replaceable>
304 <para>Sets reference ID for Z39.50 Request(s).
309 <literal>itemorder</literal>
310 <replaceable>type</replaceable> <replaceable>no</replaceable>
313 <para>Sends an Item Order Request using the ILL External.
314 <replaceable>type</replaceable> is either 1 or 2 which corresponds to
315 ILL-Profile 1 and 2 respectively. The <replaceable>no</replaceable>
316 is the Result Set position of the record to be ordered.
321 <literal>update</literal>
324 <para>Sends Item Update Request. This command sends a "minimal"
325 PDU Update to the target supplying the last received record from
327 If no record has been received from the target this command is ignored
328 and nothing is sent to the target.
335 <replaceable>filename</replaceable>
338 <para>Executes list of commands from
339 file <replaceable>filename</replaceable>, just like source on
347 <replaceable>args</replaceable>
350 <para>Executes command <replaceable>args</replaceable> in subshell
351 using the <literal>system</literal> call.
357 <literal>push_commande</literal>
358 <replaceable>command</replaceable>
361 <para>The push_command takes another command as its argument.
362 That command is then added to the history information (so
363 you can retrieve it later). The command itself is not
364 executed. This command only works if you have GNU readline/history
371 <literal>set_apdufile</literal>
372 <replaceable>filename</replaceable>
375 <para>Sets that APDU should be logged to file
376 <replaceable>filename</replaceable>. This command does the
377 thing as option <literal>-a</literal>.
383 <literal>set_auto_reconnect</literal>
384 <replaceable>flag</replaceable>
387 <para>Specifies whether YAZ client automatically reconnect if
388 target closes connection (Z39.50 only).
389 <replaceable>flag</replaceable> must be either
390 <literal>on</literal> or <literal>off</literal>.
396 <literal>set_marcdump</literal>
397 <replaceable>filename</replaceable>
400 <para>Specifies that all retrieved records should be appended ot
401 file <replaceable>filename</replaceable>. This command does the
402 thing as option <literal>-m</literal>.
408 <literal>schema</literal>
409 <replaceable>schemaid</replaceable>
412 <para>Specifies schema for retrieval.
413 Schema may be specified as an OID for Z39.50.
414 For SRW, schema is a simple string URI.
420 <literal>charset</literal>
421 <replaceable>negotiationcharset</replaceable>
422 [<replaceable>displaycharset</replaceable>]
423 [[<replaceable>marccharset</replaceable>]]
426 <para>Specifies character set (encoding) for Z39.50
427 negotiation / SRW encoding and/or character set for output (terminal).
430 <replaceable>negotiationcharset</replaceable> is the name
431 of the character set to be negotiated by the server. The special name
432 <literal>-</literal> for <replaceable>negotiationcharset</replaceable>
433 specifies <emphasis>no</emphasis> character set to be negotiated.
436 If <replaceable>displaycharset</replaceable> is given, it specifies name
437 of the character set of the output (on the terminal on which
438 YAZ client is running). To disable conversion of characters
439 to the output encoding, the special name <literal>-</literal> (dash)
441 If the special name <literal>auto</literal> is given, YAZ client will
442 convert strings to the encoding of the
443 terminal as returned by <function>nl_langinfo</function> call.
446 If <replaceable>marcharset</replaceable> is given, it specifies name
447 of the character set of retrieved MARC records from server. See
448 also <literal>marcharset</literal> command.
452 Since character set negotation takes effect in the Z39.50
453 Initialize Request you should issue this command before
454 command <literal>open</literal> is used.
459 MARC records are not covered by Z39.50 character set negotiation,
460 so that's why there is a separate character that must be known
461 in order to do meaningful converson(s).
468 <literal>negcharset</literal>
469 <replaceable>charset</replaceable>
472 <para>Specifies character set for negotiation (Z39.50). The
473 argument is the same as second argument for command
474 <literal>charset</literal>.
480 <literal>displaycharset</literal>
481 <replaceable>charset</replaceable>
484 <para>Specifies character set for output (display). The
485 argument is the same as second argument for
486 command <literal>charset</literal>.
492 <literal>marccharset</literal>
493 <replaceable>charset</replaceable>
496 <para>Specifies character set for retrieved MARC records so
497 that YAZ client can display them in a character suitable
498 for your display. See <literal>charset</literal> command.
499 If <literal>auto</literal> is given, YAZ will assume
500 that MARC21/USMARC is using MARC8/UTF8 and ISO-8859-1
501 for all other MARC variants. The charset argument is the
502 same as third argument for <literal>charset</literal> command.
508 <literal>set_cclfile</literal>
509 <replaceable>filename</replaceable>
512 <para>Specifies that CCL fields should be read from file
513 file <replaceable>filename</replaceable>. This command does the
514 thing as option <literal>-c</literal>.
520 <literal>set_cqlfile</literal>
521 <replaceable>filename</replaceable>
524 <para>Specifies that CQL fields should be read from file
525 file <replaceable>filename</replaceable>. This command does the
526 thing as option <literal>-q</literal>.
532 <literal>register_oid</literal>
533 <replaceable>name</replaceable>
534 <replaceable>class</replaceable>
535 <replaceable>OID</replaceable>
538 <para>This command allows you to register your own object
539 identifier - so that instead of entering a long dot-notation
540 you can use a short name instead.
541 The <replaceable>name</replaceable> is your
542 name for the OID, <replaceable>class</replaceable> is the
543 class, and <replaceable>OID</replaceable> is the raw OID in
544 dot notation. Class is one <literal>appctx</literal>,
545 <literal>absyn</literal>, <literal>attet</literal>,
546 <literal>transyn</literal>, <literal>diagset</literal>,
547 <literal>recsyn</literal>, <literal>resform</literal>,
548 <literal>accform</literal>, <literal>extserv</literal>,
549 <literal>userinfo</literal>, <literal>elemspec</literal>,
550 <literal>varset</literal>, <literal>schema</literal>,
551 <literal>tagset</literal>, <literal>general</literal>.
552 If you're in doubt use the <literal>general</literal>
559 <literal>register_tab</literal>
560 <replaceable>command</replaceable>
561 <replaceable>string</replaceable>
564 <para>This command registers a TAB completion string for
571 <literal>sleep</literal>
572 <replaceable>seconds</replaceable>
575 <para>This command makes YAZ client sleep (be idle) for
576 the number of seconds given.
582 <literal>zversion</literal>
583 <replaceable>ver</replaceable>
586 <para>This command sets Z39.50 version for negotiation.
587 Should be used before <literal>open</literal>.
588 By default, 3 (version 3) is used.
594 <literal>options</literal>
595 <replaceable>op1 op2..</replaceable>
598 <para>This command sets Z39.50 options for negotiation.
599 Should be used before <literal>open</literal>.
602 The following options are supported:
603 <literal>search</literal>,
604 <literal>present</literal>,
605 <literal>delSet</literal>,
606 <literal>resourceReport</literal>,
607 <literal>triggerResourceCtrl</literal>,
608 <literal>resourceCtrl</literal>,
609 <literal>accessCtrl</literal>,
610 <literal>scan</literal>,
611 <literal>sort</literal>,
612 <literal>extendedServices</literal>,
613 <literal>level_1Segmentation</literal>,
614 <literal>level_2Segmentation</literal>,
615 <literal>concurrentOperations</literal>,
616 <literal>namedResultSets</literal>,
617 <literal>encapsulation</literal>,
618 <literal>resultCount</literal>,
619 <literal>negotiationModel</literal>,
620 <literal>duplicationDetection</literal>,
621 <literal>queryType104</literal>,
622 <literal>pQESCorrection</literal>,
623 <literal>stringSchema</literal>.
629 <!-- Keep this comment at the end of the file
634 sgml-minimize-attributes:nil
635 sgml-always-quote-attributes:t
638 sgml-parent-document: "yaz.xml"
639 sgml-local-catalogs: nil
640 sgml-namecase-general:t