Mainframe Path Start learning free
Beginner6 min readLesson 4 of 4

The ISPF editor, properly

The ISPF editor is line-based and command-driven, which feels alien for about two hours and then feels fast. There are two places to type: the command line at the top, and the line-number area on the left.

Line commands — typed over the line numbers

TypeEffect
IInsert one line below (I5 inserts five)
DDelete this line (D5 deletes five; DD…DD deletes a block)
C then A/BCopy this line, then After or Before the target
M then A/BMove a line
RRepeat a line (R10 repeats it ten times)
XExclude from display (useful with FIND ALL)
COLSShow a column ruler — essential for JCL and COBOL
TABS / BNDSShow tab and boundary settings

Primary commands — typed on the command line

CommandEffect
FIND abc / F abcFind the next occurrence
F abc ALLFind all, and show a count
F abc FIRST / LAST / PREVDirectional find
CHANGE a b ALL / C a b ALLChange every occurrence
X ALL then F abc ALLHide everything, then show only matching lines — the best way to read a big file
RESETClear excluded lines and pending line commands
SORTSort lines, optionally by column range
COPY libname(member)Pull another member into this one
CREATE / REPLACEWrite selected lines out to a new member
SUBMIT / SUBSubmit the current member as a job
CANCELLeave without saving
SAVESave without leaving
HILITE COBOL / JCLTurn on syntax colouring
Excluding everything, then showing only what matters
Command ===> X ALL              Scroll ===> CSR
Command ===> F 'PROD.PAY' ALL

- - - - - - - - - - - -  47 LINE(S) NOT DISPLAYED  - - - - - - -
000210 //INFILE   DD DSN=PROD.PAY.MASTER,DISP=SHR
- - - - - - - - - - - -  12 LINE(S) NOT DISPLAYED  - - - - - - -
000388 //OUTFILE  DD DSN=PROD.PAY.RESULT,DISP=(NEW,CATLG,DELETE)
- - - - - - - - - - - -  91 LINE(S) NOT DISPLAYED  - - - - - - -

Undo

UNDO reverses your last change, but only if recovery is on — set RECOVERY ON (or set it permanently in the edit settings). Many new users discover this the hard way. CANCEL abandons all unsaved changes, which is the bigger hammer.

Common mistakes

Typing past column 71 in JCL

The system stops reading at 71 and column 72 means continuation. Long parameters must be continued on the next line, not run over.

Using CHANGE ALL without checking

Change ALL is global and instant. Do a FIND ALL first to see how many hits there are and where.

Not turning RECOVERY ON

Without it, UNDO does nothing. Set it once in your profile and forget about it.

Leaving a pending line command

A stray letter over the line numbers will act on your next Enter. RESET clears them.

What you will see at work

Key terms

Check your understanding.
Take this lesson's quiz and save your progress. Free.

Take the lesson quiz
← Option 3.4: finding and handling datasetsBack to TSO/ISPF navigation