Entering and Manipulating Data
Almost all system applications are concerned with the processing of
data.
Therefore, you should learn how to enter data ,into the system and
how to modify, store, and retrieve data after it has been entered.
Any
group of related data entered into the system is called a data set.
For
example, a data set may contain:
• Text used for information storage and retrieval.
• A source program.
• Data used as input to a program.
When you create a data set you must give it a name.
The system uses
the name to identify the data set whenever you want to modify or
retrieve it,.
The EDIT command;, which is used to create and manipulate data sets,
operates in either of two modes:
input mode or edit mode.
When you use
the EDIT command to enter data into a data set, you are using the input
mode..
When you use the EDIT command to enter subcommands to manipulate
the data in a data set you are using the edit mode.
In input mode, you can type a line of data and then enter it into the
data set by pressing the RETURN key.
You can continue entering lines of
data as long as EDIT 'is operating in input mode.
If you enter a command
or subcommand while in input mode the system adds it to the data set as
input data.
You can have the system assign a line number to each line as it is
entered,.
Line numbers make edit mode operations much easier, since you
can refer to each line by its own number.
Wh~n
you are working with a
line-numbered data set, you can request the system to print out the new
line number at the start of each new input line.
If the data set does
not have line numbers;, you can request that a prompting character be
displayed at the terminal before each line is entered.
After you finish entering data in the data set, you can switch to
edit mode by entering a null line.
(Press the RETURN key to enter a
null line.)
The system lets you know you are in edit mode by printing the
following message:
EDIT
In edit mode you can enter subcommands to point to particular lines
of the data set" to modify or renumber lines, to add and delete lines,
or to control editing of input.
When EDIT is operating in edit mode, it uses an indicator called the
current-line pointer to keep track of the next line of data to be
processed..
The operations you indicate with the subcommands are
performed starting at the line indicated by the pointer..
For example,
the DELETE subcommand deletes the line indicated by the pOinter.
After
a subcommand is executed the system repositions the pointer.
You may want to reposition the pointer before a subcommand is
executed.
You can do so by using one of two methods:
line number
editing or context editing.
Line number editing can be used only if
your data set has line numbers.
You can specify a line number as an
operand of a subcommand and the system will move the pointer to that
28
TSO Terminal User's Guide' (Release 21)