Sunday, June 10, 2007


TIP # 001

Lets start with a generic and simpler one.
Consider that you are editing a file/program and you want to know the changes you have done
since the last SAVE command.
How to find that?

Give COMPARE SESSION on the command line
Further use of COMPARE commands...
- Can be used like 3.13 option

TIP # 002

Usually the PDS or PS bears the ID of the creator or the ID of the person who modified it
recently.But is it possible to change these ID values without leaving trace of one’s own ID?

Yes its possible! In the command area against the member name or PS name, by giving ‘G’.
Dialog box will pop up allowing you to change the ID values.

TIP # 003

Suppose you are in a ISPF Screen and want to know in which TSO Region ( Development,
Production, or other TSO regions) you are now .
Issue on the command line : SAREA
ISPF STATISTICS Pop-up window will show you the region( and other info too)

TIP # 004

Any command entered in the COMMAND LINE disappears after the successful execution of its
intended function.
If you want to repeat the same command , you got to re-type it or use some PF key to retrieve the
last command entered.
But here is a cool method the make the command entered not to disappear and stay on the screen.
Precede commands with '&'

For Example:
COMMAND ===> &C '110-PARA' '220-PARA' SCROLL ===> CSR
****** ************************ TOP OF DATA **************
000003 DATE-WRITTEN. APRIL 2004.
After the execution of the command, the below command stays on the screen.
This way you can entering the same command or modifying the command a little and using it
multiple times.

TIP # 005

While trying to open any member in a PDS, we sometimes come across
"member in use" message. In that situation, if you want to know who is using the member
currently, press F1 twice.

TIP # 006

We usual search for members in a PDS by the first string of the members.
Consider this situation .
I have a PDS and I want to search it for member only by middle string of the members.
e.g. there are some members like BESTJCL1,RESTJCL2,PESTCBL1, BESTCBL2,
I want to find members which have CBL in them.
How can I search and find these members?

Use ISPF 4.12 option.
Specify the dataset to be searched and the pattern of the string.
Specify the LANG type as COB
And select the browse option.

TIP # 007

How can I find the last 10 datasets that I have accessed ?
1.GO TO ISPF 3.4 option.
2. On the top, there is a MENUBAR. Select REFLIST
3. Select Option 1 in it.
Using this option you can find out the last 30 datasets that you have accessed....

TIP # 008

Alternate to SuperCE Option(3.13) is to use the macro COMPARE .
Use this when you there is less difference between the two files.
.Open a DSN in EDIT or VIEW Mode
2. On the Command line , issue COMP 'YOUR.SECOND.COMPARISON.DSN'
3. If you want only the changes to be listed, issue COMP

TIP # 009

While Browsing Internet, we have some cool option called address autocomplete…we enter
some letters in the address bar and the browser auto completes it with the closest guess.
Does MAINFRAME has the same feature??

Yes! It has “Autocomplete” feature!!!
How to use it?
1.go to ISPF 3.4 ,
2. enter KEYS in the command line,KEYS window will popup
3. set any key to AUTOTYPE, save and exit
2. now type any Dataset partially and press the assigned PFkey!!
Note: It will not retrieve GDGs and VSAM files.

TIP # 010

I want to find a member but I don’t know the PDS to which it belongs. I only know the high
level qualifier of the PDS.
For example, lets consider high level Qualifier as MYID.MYAPPLN.* and member as MYMEM
1. Go to 3.4 and list all PDS with MYID.MYAPPLN.*
2. Now issue, MEMBER MYMEM on the command line

TIP # 011

I want to know what are the last 25 COMMAND LINE commands that I have issued from ISPF
To get that, I have to issue, RETP on the Command line.

TIP # 012

I want to edit a member, which has CBL as middle string in the PDS MY.PDS.MEMBERS.
One shortcut way is to in the ISPF 3.4 listing of the PDS,
issue S *CBL* E in the command line. If we don’t use E at the end, it will open in browse mode.

TIP # 013

Here is another tip on ISPF 3.4 Option
Usually to find the last edited member, we issue SORT CHA or SORT CHANGED on
the command line.
One can save few keystrokes by placing the cursor on any of the column
header in the ISPF 3.4, and press ENTER.
In our case, if we place the cursor on the CHANGED header, we will get the
members sorted on that column.

TIP # 014

Here is a tip by which you can avoid ISPF 3.4 Option!!!
To Open a PS or PDS member, we usually use ISPF 3.4 to open in EDIT or BROWSE
Here is one way where one can open PS or PDS member in EDIT/VIEW/BROWSE
mode from any command line.
Thus, we can avoid using 3.4 option.
Issue : EPDF ‘MYID.MYPS’ . The Dataset will be opened in EDIT MODE
If you want to open in VIEW mode:
Similarly, for opening in BROWSE mode, type BROWSE at the end.

TIP # 015

Here is a situation. I have received a maintenance change
request on one of the program.
While I am making changes to the program, one of my friend pops
in and I leave with him for a cup of coffee without SAVING the
changes I made.
After few minutes , when I am back, I am not sure what changes I
made previously on the program?
How can I find the changes I have made (without getting out of
this screen)?
Well, here is one simple command line command to achieve this...
Issue : COMP * X

TIP # 016

When I issue CUT , I know that the CUT content are placed in a
clipboard. And when I issue PASTE, the clipboard content are
But is it possible for me to view/edit the clipboard ?
One can view the clipboard after any valid CUT command was issued.
To view the clipboard, issue : CUT DISPLAY.
Clipboard manager will pop up and gives us options to edit or browse the

TIP # 017

Here is another tip on ISPF CUT. I have a dataset with 10,000
lines.I want to cut the first 10 lines and last 10 lines and
paste into another dataset.When I cut the first 10 lines and
then again the last 10 lines ,only the last 10 lines are pasted
into the new dataset.
Is there anyway out (other than doing a 2 cut & paste)?

The answer for the above question is to:
1.first cut 10 lines, then issue CUT APPEND
2.then cut last 10 lines, then issue CUT APPEND
3.When you PASTE it, you got both.

TIP # 017

Tired of typing the often-used datasets repeated?!!!
We have seen AUTOTYPE previously. Here is another one that saves lots of key-strokes.
How to use it?
1 enter KEYS in the command line,KEYS window will popup
2 set any key to NRETRIEV and exit
3 now when you are in 3.4 or whichever screen you have set the KEYS option, press the
assigned PF keys.
4. Pressing them repeated will bring up one-by-one the last 30 accessed datasets from the reflist.

TIP # 018

Here is one simple one.......
I want to search a string like 'abc' (including quote).
In my pgm there may be more abc strings.But i don't want to retrieve all of them.
i need the abc enclosed with quotes.
How to search is in 3.14 option?.
In the ISPF 3.14 , search with ‘’’abc’’’ string.(i.e. with 3 quotes at both sides of the string)

TIP # 019

I have to compare one input file field with one output file field. The input file field in is column
1 to 10 and the output file field is in column 40 to 50.
How can I do it?

1. Use the standard 3.13 ISPF option. In the same screen itself, in the command line issue, E
2. then type,
3. press PF3 and exit
4. In the New dataset , type in the output dataset
5. In the Old dataset , type in the input dataset

TIP # 020

Is an easy way to search member in Multiple PDS?
Go to 3.4 (where all the datasets will be displayed) .
In the Command line give
Command line==>M memname
This command will not work for the migrated PDS. So ensure all the PDS are in
Now the message "MEMBER(S): memname found" will apppear in the right side of
the panel.

TIP # 021

I have data which is of length 160. For some reasons, I want to wrap the data in each record to 80
characters and have the next 80 characters in the next line. So basically what I am looking for is ,
“Is there command similar to Wordwrap (as in Notepad or MS WORD) in mainframe?”
Yes, with ISPF, one can wrap the data as required.
To do that,
1.Open the dataset in ISPF EDIT mode.
2.In the first line, issue the line command: TF80 (as in this case I want to wrap to 80 chars per
3.All the subsequent lines will wrap to 80 chars per line.

TIP # 022

Here is another tip on ISPF 3.4 option
From the ISPF 3.4 option listing, I can directly Edit/Browse/view the member without listing all
the members and then select the particular member.
To do that,
In the Line command issue, E / (member)
use for Browse (B) and view (V)
Command - Enter "/" to select action Message Volume
***************************** End of Data Set list ****************************


Raj!! said...


Thanks a lot. This content is very very helpful! :) Keep the good work going!

Balaji said...



Thank you so much....It will be very useful for me

Dharmendra said...

Thats really helping.For the beginner its really help them to put them on command for controlling mainframe.

Thanks a lot.