CHANGEUP

CMS EDIT Subcommands

changeup.helpedt.txt
CHANGEUP                                                    CMS EDIT subcommand

Use the CHANGEUP subcommand to change a specified group of characters to
another group of characters of the same or a different length.  You may use the
CHANGEUP subcommand to change more than one line at a time.  The CHANGEUP
subcommand operates exactly as the CHANGE command, except that it proceeds from
the current line toward the beginning of the file.  The format of the CHANGE
subcommand is:
+----------+------------------------------------------------------------------+
| CHANGEUp | [/string1] [/string2 [/ [1|*|n [G|*]]]]                          |
+----------+------------------------------------------------------------------+
where:


/ (diagonal)
         signifies any unique delimiting character that does not appear in the
         character strings involved in the change.

string1  specifies a group of characters to be changed (old data).  string1 may
         be a null string.

string2  specifies the group of characters that are to replace string1 (new
         data).  string2 may be a null string; if omitted, it is assumed null.

n or *   indicates the number of lines to be searched, starting at the current
         line.  If * is entered, the search is performed until the end of the
         file is reached.  If this option is omitted, then only one line is
         searched.

G or *   requests the editor to change every occurrence of string1 in the lines
         specified.  If G or * is not specified, only the first occurrence of
         string1 in each line specified is changed.  If string1 is null, G or *
         may not be specified.


Usage Notes:

1.  The first nonblank character following the CHANGEUP subcommand (or any of
    its truncations) is considered the delimiter.  For example:
       c.VM/370.CMS.*
    changes the first occurrence of VM/370 to CMS on every line from the
    current line to the start of the file.

2.  If string2 is omitted, it is assumed to be a null string.  For example:
       THIS ISN THE LINE.
       change /n
       THIS IS THE LINE.
    A null string causes a character deletion.  If string1 is null, characters
    are inserted at the beginning of the line.  For example:
       THIS IS THE LINE.
       change //SO /
       SO THIS IS THE LINE.

3.  To change multiple occurrences of the same string on one line, enter:
       change/string1/string2/ 1 *

4.  The CHANGEUP subcommand can be used on typewriter terminals to display,
    without changing, any lines that contain the information specified in
    string1.  Enter:
       change /string1/string1/ * *

5.  Use the ZONE subcommand to indicate which columns are to be searched for
    string1.  If string1 is wider than the current zone, you receive the
    message:
       ZONE ERROR
    and you should either reenter the CHANGEUP subcommand or change the zone
    setting.

6.  If the character string inserted causes the data line to extend beyond the
    truncation column or the zone column, any excess characters are truncated.
    (See the description of the TRUNC subcommand for additional information on
    truncation.)

7.  You should use the ALTER subcommand when you want to change a single
    character to some special character (one that is not available on your
    keyboard).

Responses:

When verification is on, every line that is changed is displayed.

Display Mode Considerations

If you issue the CHANGEUP subcommand without operands at a 3270 display
terminal in display mode, the following occurs:

1.  The record pointed to by the current line pointer appears in the user input
    area of the display.  If the line is longer than the current truncation
    setting, it is truncated.

2.  You can then alter the record in the user input area by retyping part or
    all of the line, or by using the Insert, Delete, or Erase EOF keys to
    insert or delete characters.

3.  When the line is modified, press the Enter key.  This causes the record in
    the user input area to replace the old record at the current line in the
    output display area.

If you bring a line down to the user input area and decide not to change it,
press the Erase Input key and then the Enter key, and the line is not changed.

When a line is moved to the user input area, all nonprintable characters
(including tabs, backspaces, control characters, and so on) are stripped from
the line.  Also, any characters currently assigned to VM/370 logical line
editing symbols (#, @, cent, ") are reinterpreted when the line is reentered.
You should issue an explicit CHANGEUP subcommand to change lines containing
special characters.

The CHANGEUP subcommand is treated as an invalid subcommand if it is issued
without operands at a typewriter terminal or at a 3270 display terminal that is
not in display mode.

When you request a global change on a 3270 terminal, the display is changed
only once, to reflect the final position of the current line pointer.  The
editor displays, in the message area of the display screen:
   {nnnn|NO}  LINE(S) CHANGEUPD
to indicate the number of lines that were updated.  If the change request
resulted in the truncation of any lines, the message is displayed as:
   nnnn LINE(S) CHANGEUPD nnnn LINE(S) TRUNCATED
If the change request moves the current line pointer beyond the start of the
file, the word TOF: is displayed on the current line, followed by the first
records of the file.