home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Professional / OS2PRO194.ISO / os2 / prgramer / unix / doc / join.man < prev    next >
Text File  |  1993-06-13  |  3KB  |  133 lines

  1.  
  2.  
  3.  
  4. JOIN(1L)                                                 JOIN(1L)
  5.  
  6.  
  7. NAME
  8.        join - join lines of two files on a common field
  9.  
  10. SYNOPSIS
  11.        join  [-a  1|2]  [-v  1|2]  [-e  empty-string]  [-o field-
  12.        list...] [-t char] [-j[1|2] field] [-1 field]  [-2  field]
  13.        [--help] [--version] file1 file2
  14.  
  15. DESCRIPTION
  16.        This  manual page documents the GNU version of join.  join
  17.        prints to the standard output a  line  for  each  pair  of
  18.        input  lines,  one  each  from  file1 and file2, that have
  19.        identical join fields.  Either filename (but not both) can
  20.        be  `-',  meaning  the  standard  input.   file1 and file2
  21.        should be already sorted in increasing order (not  numeri-
  22.        cally)  on the join fields; unless the -t option is given,
  23.        they should be sorted ignoring blanks at the start of  the
  24.        line, as sort does when given the -b option.
  25.  
  26.        The  defaults  are:  the  join field is the first field in
  27.        each line; fields in the input are  separated  by  one  or
  28.        more  blanks,  with  leading  blanks  on the line ignored;
  29.        fields in the output are separated by a space; each output
  30.        line consists of the join field, the remaining fields from
  31.        file1, then the remaining fields from file2.
  32.  
  33.    OPTIONS
  34.        -a file-number
  35.               Print a line for each unpairable line in file file-
  36.               number  (either  1 or 2), in addition to the normal
  37.               output.
  38.  
  39.        -e string
  40.               Replace empty output fields (those that are missing
  41.               in the input) with string.
  42.  
  43.        -1, -j1 field
  44.               Join on field field (a positive integer) of file 1.
  45.  
  46.        -2, -j2 field
  47.               Join on field field (a positive integer) of file 2.
  48.  
  49.        -j field
  50.               Equivalent to -1 field -2 field.
  51.  
  52.        -o field-list...
  53.               Construct  each output line according to the format
  54.               in field-list.  Each element in field-list consists
  55.               of  a  file number (either 1 or 2), a period, and a
  56.               field number (a positive integer).  The elements in
  57.               the list are separated by commas or blanks.  Multi-
  58.               ple field-list arguments can be given after a  sin-
  59.               gle  -o  option; the values of all lists given with
  60.               -o are concatenated together.
  61.  
  62.  
  63.  
  64. FSF                     GNU Text Utilities                      1
  65.  
  66.  
  67.  
  68.  
  69.  
  70. JOIN(1L)                                                 JOIN(1L)
  71.  
  72.  
  73.        -t char
  74.               Use character char as the input  and  output  field
  75.               separator.
  76.  
  77.        -v file-number
  78.               Print a line for each unpairable line in file file-
  79.               number (either 1 or 2), instead of the normal  out-
  80.               put.
  81.  
  82.        --help Print a usage message and exit with a non-zero sta-
  83.               tus.
  84.  
  85.        --version
  86.               Print version information on  standard  error  then
  87.               exit.
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130. FSF                     GNU Text Utilities                      2
  131.  
  132.  
  133.