Escolar Documentos
Profissional Documentos
Cultura Documentos
These are TSO line mode commands. There is generally no ISPF screen that will do the same
thing. For help on the commands,
- on any ISPF screen, type TSO HELP;
choose a command, then type TSO HELP command-name.
or use Quick Reference by typing QW on any ISPF screen
then specify IBM as vendor
then search for TSO SYSHELP
There are 6 places you can execute TSO commands. Read the parts about continuing!
1. In a REXX program. Information about my book on REXX:
http://www.theamericanprogrammer.com/programming/index.shtml
The command must be enclosed in quotes (") or apostrophes (').
Quotes are preferred, because they conflict less
with the apostrophes that some TSO commands require.
When there is a variable in the command you want REXX to process the variable.
Quotes prevent REXX from processing the variable.
Remove the variable from the quotes.
Example of an ALLOCATE with the dataset name in a variable.
Dataset_Name = "MY.DATA"
"ALLOC DDN(INFILE) SHR REUSE DSN("Dataset_Name")"
Commands for ISPF editor are prefixed by ADDRESS ISREDIT, for example:
ADDRESS ISREDIT "CHANGE ALL DNS DSN"
Continuing. Break the command into two parts. End the first part with a hyphen
or +. The + causes leading spaces on the next line to be deleted..
EXAMPLE:
ALLOC DDN(INFILE) SHR REUSE -
DSN(&DATASET_NAME)
From http://www.theamericanprogrammer.com commercial use or resale of this document is a violation of copyright laws.
3. In ISPF Option 6.
Enter the command as shown in the examples
Example of an ALLOC command in ISPF Option 6:
ALLOC DSN(MY.DATA) SHR REUSE DDN(INFILE)
5. In line mode TSO, known as "Ready mode". I.E., you are not in ISPF.
Enter the command as shown in the examples
Example of an ALLOCATE command in line mode TSO.
ALLOC DDN(INFILE) SHR REUSE DSN(MY.DATA)
Example in context:
//STEP1 EXEC PGM=IKJEFT01,DYNAMNBR=200
//SYSPRINT DD SYSOUT=*
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
ALLOC DDN(INFILE) SHR REUSE DSN(MY.DATA)
/*
Connect a catalogued disk file/ dataset to a program for use as input or output
ALLOCATE with the SHR or OLD keyword and the DDN keyword
ALLOC DDN(ddname) SHR REUSE DSN(dataset-name)
Connect a catalogued library member/pds member to a program for use as input or output
ALLOCATE with the SHR or OLD keyword and the DDN keyword
ALLOC DDN(ddname) SHR REUSE (continued)
DSN(library-name(member-name))
Note that the library must exist.
The member must exist if it is input.
The member will be created or overwritten, if it is output.
Connect a catalogued disk file/ dataset to a program for use as output, lengthening (append)
the file
ALLOCATE with the MOD keyword and the DDN keyword
ALLOC DDN(ddname) MOD REUSE DSN(dataset-name)
Create a catalogued disk file/dataset, or library/ pds that has the same attributes as another
ALLOCATE with the LIKE keyword
ALLOC DSN(dataset-name) LIKE(other-dataset-name)
Remove the connection between a file and a program that has been established with
ALLOCATE and the DDN keyword
FREE DDN(ddname)
Display the dataset names, library names, and DDNAMES currently in use in your TSO
session.
LISTALC STATUS HISTORY SYSNAMES
List the names of datasets or libraries whose names begin with a specific high level qualifier.
LISTCAT LEVEL(high-level-qualifier)
Example:
LISTCAT LEVEL(USERID1)
Transmit a message to a TSO user. Cancel the message if the user can’t receive messages or is
logged off.
SEND 'the message' USER(the-userid) -userid may be *, which means to yourself
Transmit a message to a TSO user. Wait until the user is able to receive the message.
SEND 'the message' USER(the-userid) WAIT
the-userid may be *, which means to yourself
Transmit a message to a TSO user. The message will be delivered at once if the user is logged
on. It will be delivered when the user logs on, if the user is now logged off.
SEND 'the message' USER(the-userid) LOGON
the-userid may be *, which means to yourself
Display the current time, CPU time used, service units used, and date
TIME
Turn off prompting - commands asking you for missing or invalid information
PROFILE NOPROMPT
Find out if TSO is prefixing your logon userid to dataset names specified without apostrophes.
PROFILE
Make TSO prefix your logon userid to dataset names specified without apostrophes.
PROFILE PREFIX(your-userid) The default
Stop TSO from prefixing your logon userid to dataset names specified without apostrophes.
PROFILE NOPREFIX Not Recommended
Execute a REXX program or CLIST that is not found on a library assigned to SYSEXEC
"EXEC 'libry-name(member-name)' 'parameters if any.' " EXEC
Cancel a job that you have submitted and discard the printed output
CANCEL jobname(job-number) PURGE
Send JCL to MVS batch for processing I.E. spawn a detached process
SUBMIT dataset-name or library(member-name)
Retrieve the most recent backup copy of a dataset or library that has been backed up
HRECOVER dataset-name
Retrieve the backup copy of a dataset or library that was created before the most recent one
HRECOVER dataset-name GENERATION(1)
Components are:
ISPPLIB Panel library
ISPSLIB File Tailoring Skeleton Library
ISPMLIB Message library
ISPFILE File Tailoring output library
ISPTLIB Table input
ISPTABL Table output
ISPLLIB Load module
Prevent an ISPF error from kicking you out of your session. (Hides diagnostic messages)
CONTROL ERRORS RETURN
REXX Example:
ADDRESS ISPEXEC "CONTROL ERRORS RETURN"
Created by http://www.theamericanprogrammer.com. You may copy this document provided this notice is attached.
Explanations by line.
Line 1. EDIT 'fully-qualified-dataset-name' DATA OLD NONUM EMODE
Please use a fully-qualified dataset name, with apostrophes.
Line 2.
TOP.
Position yourself at the top of data (important for the change command)
Line 3.
Change character strings on each line from current line position
(shown by *) to the end (shown by 999)
CHANGE * 999 'old string' 'new string'
Line 4.
Send the data you are editing (if it's JCL) to MVS batch for processing
I.E. spawn a detached process
SUBMIT
Line 5.
Exit without saving data in the name you started with
END NOSAVE
Save what you are editing with a specific name other than the one you started with
SAVE new-name REUSE
The above example in a REXX program. You must queue the commands. They will be executed
after the REXX program ends. You may not put anything else into the queue since that will
interfere with this.
The above example in a CLIST. There is no change from the example above. The CLIST will
execute the commands line by line. After finishing the commands, control will remain in the
CLIST.
REXX Reference
All REXX verbs, keywords, and built-in functions as found in MVS, VM/CMS and OS/2.
About 100 pages. Ready to ship.
Order from MVS Training (800) 356 9093. http://www.mvs-training.com