home *** CD-ROM | disk | FTP | other *** search
/ norge.freeshell.org (192.94.73.8) / 192.94.73.8.tar / 192.94.73.8 / pub / computers / pdp10 / tops-10 / sort.hlp < prev    next >
Text File  |  1995-04-05  |  5KB  |  154 lines

  1. HLP:SORT.HLP (2 pages)
  2.  
  3. DEC's SORT-MERGE program (about 2 to 4 times more efficient than CSORT).
  4. This can be used as a stand-alone program or called from Fortran or Cobol.
  5. To be used as a stand-alone basis, first type:
  6.     R SORT
  7. The program will respond with a "*".  It is then ready to receive
  8. a command line.  After a command is entered and completed, a "*"
  9. will again be displayed, then another command may be entered, or
  10. "/EXIT" or <cntl>C or <cntl>Z may be entered to exit from SORT.
  11.  
  12.  
  13. Shortest sort command format:
  14. out.fil=in.fil/R:n/K:n:m
  15.  
  16. The /CORE switch is usually well worth using for moderate to large
  17. files.  Savings of a factor of 2 in cost are not difficult to achieve.
  18. Left to itself SORT will use large amounts of core without much gain
  19. in speed.  Try /CORE:20K and try more or less core to really find the
  20. most efficient values.  Unfortunately the most efficient values not
  21. only depend on the size and nature of the file, but also on the
  22. initial order so no general rules can be given.
  23.  
  24. General command format for SORT and MERGE:
  25. OUT.FIL/SW,SW,...= IN.FIL/SW,SW,.../FUNCTION
  26.  
  27. Functions are:
  28. /EXIT   takes no arguments
  29. /HELP   takes no arguments
  30. /MERGE  see below
  31. /RUN (program) file-spec
  32. /SORT   see below (default)
  33.  
  34. indirect command files may be used:  @filspec
  35.  
  36. SORT and MERGE Switches are:
  37. /RECORD:<n>     n = maximum record size (does not imply /FIXED)
  38.  
  39. /KEY:<n>:<m>:<x>  the first two arguments are mandatory
  40.   <n>           position of first KEY character
  41.   <m>           length of the KEY
  42.   <x>           can be ASCENDING, or DESCENDING
  43. Key data type switches:
  44.   /ALPHANUMERIC
  45.   /COMP1
  46.   /COMP3
  47.   /COMPUTATIONAL
  48.   /FORMAT:a<b>.<c> where a<b>.<c> is a FORTRAN format descriptor
  49.      a  = D decimal floating point, double precision
  50.           E decimal floating point, single precision
  51.           F decimal fixed point
  52.           G general
  53.     <b> = KEY length
  54.     <c> = number of decimal places
  55.   /NUMERIC
  56.   /SIGNED       key operational sign is to be used
  57.   /UNSIGNED     key operational sign is to be ignored
  58.  
  59. /ALIGN          word align all ASCII output records
  60. /ASCII          recording mode
  61. /BINARY         recording mode
  62. /EBCDIC         recording mode
  63. /SIXBIT         recording mode
  64.  
  65. /BLOCKED:<n>    COBOL blocking factor
  66. /FIXED          fixed length records
  67. /FORTRAN        FORTRAN type data file
  68. /RANDOM         must also use /FORTRAN when sorting Fortran random access files
  69. /SEQUENTIAL     same as /VARIABLE
  70. /VARIABLE       variable length records
  71.  
  72. /BUFFER-PAGES<n> number of pages for IO buffers
  73. /CHECK          when merging check the sequence of the input record key
  74. /COLLATE:<a>    <a> is one of the following
  75.   ASCII         collating sequence
  76.   EBCDIC        collating sequence
  77.   FILE:file-spec
  78.   LITERAL:/collating-sequence/  first char after colon is delimeter
  79.   ADDRESS:<N> octal address
  80. /CORE:<n>K  or  <n>P   specifies low segment core to be used in K (1024 words,
  81.                        default) or in pages (512 words)
  82. /ERROR-RETURN:<n> octal address
  83. /FATAL-ERROR-CODE:<n> octal address
  84. /LEAVES:<n>     <n> is the number of records to keep in main memory
  85. /PHYSICAL       do not use logical names
  86. /SUPPRESS-ERROR:<a> <a> is one of the following
  87.   ALL
  88.   FATAL
  89.   INFORMATION
  90.   NONE
  91.   WARNING
  92. /TEMPORARY-AREAS:directory-name,...
  93.  
  94. /ANSI-ASCII     alias STANDARD ASCII for mag-tape
  95. /DENSITY:<a>    <a> is one of the following
  96.   200
  97.   556
  98.   800
  99.   1600
  100.   SYSTEM-DEFAULT
  101. /INDUSTRY       industry compatible (8 bit) mode for mag-tape
  102. /LABEL:<a>      <a> is one of the following
  103.   ANSI
  104.   DEC
  105.   IBM
  106.   NONSTANDARD
  107.   OMITTED
  108.   STANDARD
  109. /PARITY:<a>     <a> is one of the following
  110.   EVEN
  111.   ODD
  112. /REWIND         before use
  113. /UNLOAD         after use
  114.  
  115. Examples:  (All the switches below may be abbreviated to one character.)
  116.  
  117. TEST.OUT=TEST.IN/REC:70/KEY:21:10:DESC/CORE:20K
  118. a descending sort (default is ascending)
  119.  
  120. TEST.OUT=TEST.IN/REC:70/KEY:21:10/FORMAT:F10.4/CORE:20K
  121. sort in numeric order on a field that has a decimal point
  122. (which actually may be anywhere in the field)
  123.  
  124. TEST.OUT=TEST.IN/REC:70/KEY:21:10/KEY:41:5/CORE:20K
  125. a two key sort, key given first is primary
  126.  
  127. TEST.OUT=TESTA.IN,TESTB.IN/REC:70/KEY:21:10/CORE:20K/MERG
  128. merge two similar, pre-sorted files
  129.  
  130. TEST.OUT=TESTA.IN,TESTB.IN/REC:70/KEY:21:10/CORE:20K
  131. merge and sort two similar files.  That's right, without the "/MERG",
  132. the output file will be merged and sorted.
  133.  
  134. For more information see DEC's SORT/MERGE User's Guide.  This is
  135. a (shock) well written manual that even includes a beginner's section.
  136.  
  137. Multi-line sets can be sorted if they are fixed length.  When counting
  138. characters, include the <CR> <LF> characters on all lines execpt the
  139. last when giving the record length.  References to positions in the set
  140. must also take into account the <CR> <LF> characters.
  141.  
  142. Note:  SORT-MERGE is smart enough to look at all the disks available
  143. to you and use them for its temporary sorting files.  But it is not
  144. smart enough to stop using a disk when its quota is being exceeded!
  145. So--If you sort a large file and have a disk with a small quota, you
  146. should DISMOUNT that small-quota-disk first.  The DISMOUNT would be
  147. only a logical opperation--making the system ignore the presence of
  148. that disk as far as your job is concerned.  Example: .DISMOUNT DSKB
  149.  
  150. [end SORT help file]
  151. las
  152. .KJOB
  153. .
  154.