Title: ITM How to Edit a Data Set
1ITM How to Edit a Data Set
- Module 4
- Chapter 4 Topic 1, 2, and 3,
- Pages 103 174
2Objectives
- Basic Edit Operation
- Specify a file or member
- Basic edit commands
- Save edited data
- Edit Profile
- What is it?
- Changing a profile
- Save a profile
- Advanced Edit Commands
3Topic 1 Basic Edit Operation
- Using the ISPF Text Editor
- Used for PDS members most often
- Also sequential data sets
- Records must be lt 255 bytes
- ISPF reads entire member in VS
- Terminate edit saves changes to disk
4Starting Edit
- Option 2 on Primary Option Menu
- User provides
- Project
- Group
- Type
- Member
- Can provide a member with a pattern or blank
- Displays a member list
- Place S to select a member name
- See Figure 4-2, Page 107
5Edit Data Display
- Three distinct areas
- Heading Area
- Line Command Area
- Screen Window
6Heading Area
- Top two screen lines
- Informative Messages
- Enter commands
- At Kirkwood, it is at the bottom of the screen
7Line Command Area
- First six columns of lines 3-24
- One line for each source member
- Can enter line commands
- i.e. Deleting and Inserting Lines
8Screen Window
- Remaining columns after column 6
- Only 72 characters display
- PF10/PF22 to move window left
- PF11/PF23 to move window right
- PF7/PF19 to move window up
- PF8/PF20 to move window down
- Holds source member data
- Change data by
- Overwriting
- Terminal editing keys
- Insert, Delete, Erase E-O-F keys
9Line Numbers
- AKA, Sequence Numbers
- Two Numbering Formats
- COBOL
- Six digits long
- Numbers stored in first six positions of each
record - Standard (STD)
- Eight digits long
- Only last six displayed
- Fixed length records
- Numbers stored in last eight positions
- Variable length records
- Numbers stored in first eight positions
10Types of Commands in Edit
- Primary Commands
- Entered in Command Input Area
- Generally apply to entire source member
- Line Commands
- Entered in Line Command Area
- Apply to individual lines
- Type over the line numbers
11Line Command Examples
- Insert Lines
- Delete Lines
- Repeat Lines
- Copy and Move Lines
- Use RENUM to renumber
12Insert Lines
- I
- Insert a single line following this line
- In
- Insert n lines following this line
- See Figure 4-5, Page 111-112
13Delete Lines
- D
- Delete this line
- Dn
- Delete n lines starting with this line
- DD
- Delete the block of lines beginning with the
first DD command and ending with the second DD
command - See Figures 4-6 and 4-7, Page 114-115
14Repeat Lines
- R
- Repeat this line
- Rn
- Repeat this line n times
- RR
- Repeat a block of lines
- RRn
- Repeat a block of line n times
- See Figures 4-8 and 4-9, Page 116-117
15Copy Lines
- C
- Copy this line
- Cn
- Copy n lines starting with this line
- CC
- Copy a block of lines
- See Figure 4-10, Page 119
16Move Lines
- M
- Move this line
- Mn
- Move n lines starting with this line
- MM
- Move a block of lines
- See Figure 4-11, Page 120
17Copy and Move Line Destination
- A
- Copy or move lines after this line
- An
- Repeat the copy or move n times after this line
- B
- Copy or move lines before this line
- Bn
- Repeat the copy or move n times before this line
18RESET Command
- Used to remove informational messages or error
messages - Doesnt affect actual text
19Create a New Member
- Specify member on Edit Entry Panel
- Creates empty space in VS
- See Figure 4-1, Page 105
- Initially no line numbers or source data
- Figure 4-12, Page 122
20Terminate Edit
- With saving member
- PF3/15
- Returns to edit entry panel
- PF3/15 again to return to main menu
- SAVE on command input area
- Doesnt end edit
- Without saving member
- CANCEL or CAN on command input area
21Topic 2 How to Control the Edit Profile
- Edit Profiles control editing options
- Tabs, column boundaries, line numbers
- ISPF maintains separate edit profiles
- Correspond to data set types
- i.e. COBOL profile
22Display Edit Profile
- Enter PROFILE in command input area
- Lines indicate
- Profile name
- Record format and length
- Various edit mode setting
- Settings saved when edit terminated
- Unless profile locked
23Controlling Profiles
- Switch or create a profile
- In command input area
- Switch by specifying different profile
- Create by specifying a new profile
- Uses current profile settings
- Lock a Profile
- Any changes only affect current session
- Type PROFILE LOCK in command input area
- Exceptions
- CAPS, NUMBER, PACK, and STATS
24Four Important Profile Settings
- Tabs
- Boundary Control
- Masking
- Line numbering
25Tabs - Types
- To cursor to a particular location (tab stop)
- Two Types
- Hardware
- Use 3270s Tab key
- Uses a special control character (attribute byte)
- Takes up one position on the screen
- Displays as blank
- Logical
- Enter a special tab character to set tab stops
- Advances with the ENTER key
- Used at Kirkwood
- See Figure 4-15, Page 129
26Controlling Tabbing
- Two Commands
- TABS line command
- Defines location of each tab stop
- TABS primary command
- Activates or deactivates tabs
27Defining and Activating Tab Stops (at Kirkwood)
- With PROFILE open
- Enter COLS in the line command area
- Displays column numbers
- Enter TABS in the line command area
- Set tab stops with a
- Use spacebar for blank areas
- Enter TABS ON primary command
- Activates tabs
28Boundary Control
- Determines the range of columns in edit
- For COBOL
- Right margin is column 7
- Left margin is column 72
- At Kirkwood
- Dont use Boundary command
- Profile changed to NUM ON STD COB
29Edit Masking
- Pre-defined line for initial contents inserted
lines - Generally blank
- Use MASK line command to change
- Remove a MASK line with the D line command or
RESET primary command - Deactivate with MASK line command containing only
blanks
30Line Numbering
- AKA, sequence numbers
- Five commands
- NUMBER
- NONUMBER
- AUTONUM
- RENUM
- UNNUM
31NUMBER and NONUMBER
- Defines how line numbers are stored
- NUMBER ON / OFF STD / COBOL / STD COBOL
- Edit checks if member has valid COBOL and
STANDARD line numbers - NUMBER DISPLAY
- Displays generated sequence numbers in data
window - NONUMBER
- Turns number mode off
32AUTONUM
- Controls if a member is/isnt renumbered
automatically when saved - Normally off
- AUTONUM ON / OFF
33RENUM and UNNUM
- RENUM to resequence line numbers
- Starts with 100, then by 100s
- RENUM ON / OFF STD / COBOL / STD COBOL
- Resequences line numbers unless OFF is specified
- RENUM DISPLAY
- UNNUM to remove line numbers
- Blanks replace line numbers
- Turns off NUMBER mode
34Other Edit Modes
- STATS (Page 138 140)
- Controls automatic maintenance of library
statistics - NULLS (Page 140)
- Controls how trailing blanks are handled on the
3270 screen - If ON, must use space bar
35Other Edit Modes (cont.)
- AUTOLIST (Page 141)
- Controls automatic source list printing
- RECOVERY (Page 141)
- Controls automatic journal kept for recovery
purposes - UNDO available
- HEX (Page 141 142)
- Controls hexadecimal display
36Other Edit Modes (cont.)
- CAPS (Page 142)
- Controls automatic conversion of lowercase data
to uppercase - Normally OFF for text data
- LC or UC for specific lines
- LCn or UCn for lines starting with the current
line - LCLC or UCUC for block of lines beginning with
the first and ending with the second command
37Other Edit Modes (cont.)
- PACK (Page 143)
- Controls how data is stored
- Compressed or not
- AUTOSAVE (Page 143 144)
- Controls automatic saving of modifications
- NOTES (Page 144)
- Controls displaying of notes
38Topic 3 Advanced Edit Options
- IMACRO (Page 144)
- Control the edit macro run at start of an edit
session - FIND (See Module 5)
- Find a character string
- CHANGE (See Page 147)
- Find a character string and replace with another
string
39CHANGE Command Syntax
- FIND / CHANGE
- string-1
- string-2
- range
- NEXT / PREV / FIRST / LAST / ALL
- CHARS / PREFIX / SUFFIX / WORD
- X / NX
- col-1 col-2
40CHANGE Parameters
- FIND
- Look for string-1
- CHANGE
- Look for string-1
- If found, replace with string-2
- string-1
- Text string to be found
- Use apostrophes or quotes if contains spaces or
commas - Hex string as Xhex-digits
- Text string as Ttext-string
- Picture string as Ppicture-string
41CHANGE Parameters (cont.)
- string-2
- Replacement for string-1
- In apostrophes or quotes if contains spaces or
commas - Hex value as Xhex-digits is only for CHANGE
- Range
- Range of lines identified by two labels
- Default is first and last lines of the file
42CHANGE Parameters (cont.)
- NEXT
- Starts at current line and locates next
occurrence of string-1 - The default
- PREV
- Starts at current line and locate the previous
occurrence of string-1 - Search backwards
- FIRST
- Starts at top and locates first occurrence of
string-1
43CHANGE Parameters (cont.)
- LAST
- Starts bottom and locates first occurrence of
string-1 - Search backwards
- ALL
- Same as FIRST, but indicates count of the
occurrences of string-1 - CHARS
- Any occurrence of string-1 satisfies the search
- Default
44CHANGE Parameters (cont.)
- PREFIX
- String-1 must be at the beginning of a word to
satisfy the search - SUFFIX
- String-1 must be at the end of a word to satisfy
the search - WORD
- String-1 must be surrounded by spaces or special
characters to satisfy the search
45CHANGE Parameters (cont.)
- X and NX
- Control the search of excluded lines
- X says to search only excluded lines
- Can use EXCLUDE primary command
- NX says to search only lines not excluded
- If not specified, all lines are searched
- col-1
- Starting column number
- If col-2 not specified, string-1 must begin in
this column to satisfy the search - Default is current left boundary
46CHANGE Parameters (cont.)
- col-2
- Ending column number
- If specified, string-1 must be found between
col-1 and col-2 to satisfy the search - Default is current right boundary
47Excluding and Redisplaying Lines
- X - excludes a single line
- Xn - excludes n lines
- XX - excludes this line and all lines between
two XX commands - F - Shows the first line of the excluded text
- Fn - Shows the first n lines
- L - Shows the last line of the excluded text
- Ln - Shows the last n lines
- S - Shows one line of the excluded text
- Sn - Shows n lines
48EXCLUDE Primary Command
- Locates lines with a specific character and
excludes the lines from the display - Command Syntax
- EXCLUDEstring-1range NEXT / PREV / FIRST /
LAST / ALL CHARS / PREFIX / SUFFIX / WORD
col-1 col-2
49EXCLUDE Parameters
- EXCLUDEstring-1range NEXT / PREV / FIRST /
LAST / ALL CHARS / PREFIX / SUFFIX / WORD
col-1 col-2
50EXCLUDE Parameters (cont.)
- string-1
- Text string to be found
- Use apostrophes or quotes if contains spaces or
commas - Hex string as Xhex-digits
- Text string as Ttext-string
- Picture string as Ppicture-string
- Range
- Range of lines identified by two labels
- Default is first and last lines of the file
51EXCLUDE Parameters (cont.)
- NEXT
- Starts at current line and locates next
occurrence of string-1 - The default
- PREV
- Starts at current line and locate the previous
occurrence of string-1 - Search backwards
- FIRST
- Starts at top and locates first occurrence of
string-1
52EXCLUDE Parameters (cont.)
- LAST
- Starts bottom and locates first occurrence of
string-1 - Search backwards
- ALL
- Same as FIRST, but indicates count of the
occurrences of string-1 - CHARS
- Any occurrence of string-1 satisfies the search
- Default
53EXCLUDE Parameters (cont.)
- PREFIX
- String-1 must be at the beginning of a word to
satisfy the search - SUFFIX
- String-1 must be at the end of a word to satisfy
the search - WORD
- String-1 must be surrounded by spaces or special
characters to satisfy the search
54EXCLUDE Parameters (cont.)
- col-1
- Starting column number
- If col-2 not specified, string-1 must begin in
this column to satisfy the search - Default is current left boundary
- col-2
- Ending column number
- If specified, string-1 must be found between
col-1 and col-2 to satisfy the search - Default is current right boundary
55DELETE Primary Command
- Used to delete excluded or non-excluded lines
- Command Syntax
- DELETEALLRANGEX/NX
56DELETE Parameters
- ALL
- Delete all lines within specified range or are
excluded or not excluded - Cant specify ALL by itself
- Range
- Range of lines identified by two labels
- Default is first and last lines of the file
57DELETE Parameters (cont.)
- X
- Delete only excluded lines
- NX
- Delete only non-excluded lines
58DELETE Parameters (cont.)
- X
- Delete only excluded lines
- NX
- Delete only non-excluded lines
59LOCATE Primary Command
- Used to position the display at a known point in
the file - Command Syntax
- LOCATE NEXT / PREV / FIRST / LASTCHANGE
/LABEL / EXCLUDED / ERROR / COMMAND /
SPECIALRANGE
60LOCATE Parameters
- NEXT
- Starts at current line and locates next
occurrence of the specified line type - PREV
- Starts at current line and locate the previous
occurrence of the specified line type - FIRST
- Starts at top and locates first occurrence of
specified line type
61LOCATE Parameters (cont.)
- LAST
- Starts bottom and locates first occurrence of
specified line type - CHANGE
- Search for line with a change flag (CHGgt) in
the line command area - LABEL
- Search for a line with a label
62LOCATE Parameters (cont.)
- EXCLUDED
- Search for an excluded line
- ERROR
- Search for a line with an error flag (ERRgt) in
the line command area - COMMAND
- Search for a line with a pending line command
- Tabs line
63LOCATE Parameters (cont.)
- SPECIAL
- Search for any of the following special lines
- Bounds lines
- Column identification line
- Information line
- Mask line
- Message line
- Note line
- Profile line
- Range
- Range of lines identified by two labels
- Default is first and last lines of the file
64Shifting Source Text
- Used to shift the contents of a line or group of
lines one or more positions to the left or right - Two types
- Column
- Data moves a specified number of columns left or
right - Data shifted beyond margins in lost
- Spaces inserted where needed
- Data
- Non-blank characters not deleted
- Words are not combined
- Spaces with apostrophes are not deleted
65Data and Column Shift Syntax
66Working with External Data Sets (Merging and
Segmenting)
- Data sets other than the one youre editing
- Copy or move lines from another data set or
member - Copy or move lines
- To another data set or member
- To create another data set or member
67Related Commands
- COPY member AFTER/BEFORE Label
- Copy member to position marked by an A or B line
command or the specified label - MOVE member AFTER/BEFORE Label
- Copy member to the position marked by an A or B
line command or the specified label - Delete the member from its original location
68Related Commands (cont.)
- CREATE member range
- Create member with the range of lines marked by C
or M commands or the specified labels - REPLACE member range
- Create member or replace existing member with the
range of lines marked by C or M commands or the
specified labels - If member name omitted
- Panel displays to enter the data set or member
69Parameters
- AFTER
- Data placed after line that contains the label
you specify - BEFORE
- Data placed before line that contains the label
you specify - LABEL
- User defined
- To declare
- Scroll file so the line appears top of screen
window - Enter a period followed by a one- to
eight-character label in the command area - Period is required when defined
70Recursive Editing
- Done from within current edit session
- EDIT command
- Syntax
- EDIT member
- Alternative to Split Screen
71Summary
- Basic Edit Operation
- Specify a file or member
- Basic edit commands
- Save edited data
- Edit Profile
- What is it?
- Changing a profile
- Save a profile
- Advanced Edit Commands