EDIT PPRINT EXEC CLP ---) TOF: o (null line)
1 SCONTROL OFF 2 SP =
3 SIF .S1 EQ SEXIT 100 4 SFN = S1 5 SIF S1 EQ ? SGOTO -TELL
6 SNFN = SCONCAT $ S1 7 SIF .S2 EQ SEXIT 200 8 SFT = S2 9 SFM = S3 10 SIF .S3 NE SSKIP 2
11 SFM = A
12 SSKIP 3
13 SIF S3 NE ( SSKIP 2
14 SFM = A
15 SP = (
16 SCONTROL ALL
17 COpy SFN SFT SFM SNFN SFT A ( UNPACK 18 PRINT SNFN SFT A SP S4 S5 S6 S7 S8 S9 S10 S11 S12 S13 S14 19 ERASE SNFN SFT A 20 SEXIT 21 -TELL STYPE THIS EXEC PRINTS A LISTING FROM PACKED FORMAT EOF: The line numbers represented are symbolic: they are not an actual
part of the file, but are used below to indicate at which line the
current line pointer is positioned after execution of the EDIT
subcommand indicated.
Subcommand DOWN 5 UP LOCATE /UNP/ TYPE 3 BOTTOM DOWN FIND - TOP CHANGE /EQ/EQ/
DELETE 2 INPUT *
6 CLP position
---) 0 ---) 5
---) 4
---) 17
---) 19
---) 21
---) EOF: ---) 21
---) 0 ---) 5
---) 7 (lines numbered 5 and 6 are deleted)
---) the line just entered (between 7 and 8)
Figure 5. Positioning the Current Line Pointer Verification and Search Columns ,
There are two EDIT subcommands you can use to control what you and the
editor "see" in a file. The VERIFY subcommand controls what you see
displayed; the ZONE subcommand controls what columns the editor
searches. Normally, when you edit a file, every request that you make
of the editor results in the display of one or more lines at your
terminal. If you do not want to see the lines, you can specify:
verify off
68 IBM VM/370 eMS User's Guide
Alternatively, if you want to see only particular columns in a file, you
can specify the columns you wish to have displayed:
verify 1 30 Some filetypes have default values set for verification, which
usually include those columns in the file that contain text or data, and
exclude columns that contain sequence numbers. If a verification column
is less than the record length, you can specify:
verify *
to indicate that you want to see all columns displayed.
In conjunction with the VERIFY subcommand, you can use the ZONE subcommand to tell the editor within which columns it can search or
modify data. When you issue the subcommand:
zone 20 30 The editor ignores all text in columns 1-19 and 31 to the end of the
record when it searches lines for LOCATE, CHANGE, ALTER, and FIND
subcommands. You cannot unintentionally modify data outside of these
fields; you must change the zones in order to operate on any other data.
The zone setting also controls the truncation column for records when you are using the CHANGE subcommand; for more details, see "Setting Truncation Limits."
Changing, Deleting, and Adding Lines You can change character strings in individual lines of data with the
CHANGE subcommand. A character string may be any length, or it may be a
null string. Any of the characters on your terminal keyboard, including
blanks, are valid characters. The following example shows a simple data
line and the cumulative effect of CHANGE subcommands.
ABC ABC ABC
is the initial data line.
CHANGE /ABC/XYZ/ changes the first occurrence of the character string "ABC" to the
string "XYZ". XYZ ABC ABC
CHANGE /ABC//
deletes the character string "ABC" and concatenates the characters
on each side of it. XYZ ABC
CHANGE //ABC/
inserts the string "ABC" at the beginning of the line. ABCXYZ ABC
CHANGE /XYZ /XYZ/ deletes one blank character following "XYZ". ABCXYZ ABC Section 5. The CMS Editor 69
Previous Page Next Page