Usage:
------
Format: IPSORT column[q] input-file [output-file]

  column      = column in which IP addresses begin
                (if positiv number then ascending sort,
                if negativ number then descending sort)
  q           = suppress informational messages
  input-file  = input text file with IP addresses
  output-file = sorted output file (must be other
                name than input file, if omitted then
                output-file = input-file.OUT)


Description:
------------
IPSORT.EXE sorts lines of a text file with a sorting key of
IP addresses located in the lines at a particular column.
This column must be specified as a parameter (a positiv or negativ
number between 1 and 122). The sorting order of the IP addresses is
ascending when the column parameter is positiv and it is descending when
the column parameter is negativ. Lines with no valid IP addresses
at the specified column are ignored and do not appear in the sorted
output file.
The IP addresses must be in the dot notation a.b.c.d with
a,b,c and d between 0 and 255. IP addresses at the specified
column may have leading spaces or tabs. The end of the IP address
(this means the end of the d-address part) in the line is
automatically detected and defined by either the end of the
line (carriage return), a space or a tab or a non-numerical character.
If the d-address-part is immediately follwed by another number then
the first 3 digits are taken as the d-address part.

Here are some examples:
192.168.16.213 host1           detected IP address is 192.168.16.213
   10.1.2.33number             detected IP address is 10.1.2.33
010.1.2.1234567                detected IP address is 010.1.2.123
192.168.1.255<CR><LF>          detected IP address is 192.168.1.255
2.3.4.345                      invalid IP address (345 not allowed)

When You append the character q (for quiet) to the column parameter
then informational messages are suppressed (error messages are not
suppressed).

Informational messages show
 - the maximum number of input lines which can be read
   (ca. 3500, depending on free 640K-DOS-memory)
 - the process of reading input lines and detecting lines with
   valid IP addresses
 - the start of the sorting routine
 - the process of writing the sorted output lines

The sorted output lines in the output file are truncated after
column 128! Trailing tabs or spaces are removed.


Examples:
---------
Example: IPSORT 15 ADDRESS.LIS
            input-file ADDRESS.LIS is sorted to
            output-file ADDRESS.OUT with ascending
            IP addresses beginning in column 15

Example: IPSORT -1q C:\NET\IP.TXT C:\TEST\ADDR.LIS
            input-file C:\NET\IP.TXT is sorted to
            output-file C:\TEST\ADDR.LIS with
            descending IP addresses beginning in column 1,
            no informational messages on your screen.


Additional information:
-----------------------
My program is freeware and may be distributed freely.

If You like the program or have any comments please send me a
postcard from Your home town to:

  Siegbert Mueller
  Priel 15
  88709 Meersburg
  GERMANY

My Email address is: smueller@debis.com

History:
Version 1.0 in May 1998  :
  First issue
Version 1.1 in June 1998 :
  Internal error fixed

