Tso Commands
Tso Commands
Terms
TSO Commands, TSO Line Mode Commands - TSO Native Mode Commands Tutorial
TSO - Time Sharing Option of IBM's mainframe operating system MVS (also called
OS/390 or Z/OS).
TSO is an on-line interactive program development system that gives access to the
same files as with batch (JCL) jobs.
TSO is used to:
create, maintain and compile programs
create, maintain and submit JCL to run jobs
inspect the printed or displayed output of JCL jobs
interactively test both batch and on-line programs
- on any ISPF screen, type TSO HELP; (If you are outside of ISPF just type HELP)
When there is a variable in the command you want REXX to process the variable.
Dataset_Name = "MY.DATA"
In a REXX program commands for ISPF are prefixed by ADDRESS ISPEXEC, for example:
Commands for ISPF editor are prefixed by ADDRESS ISREDIT, for example:
Enclose each part in quotes. End the first part with a comma.
EXAMPLE:
"DSN(MY.DATA)"
2. In a CLIST.
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:
DSN(&DATASET_NAME)
3. In ISPF Option 6.
5. In line mode TSO, known as "Ready mode". I.E., you are not in ISPF.
Example in context:
//SYSPRINT DD SYSOUT=*
//SYSTSPRT DD SYSOUT=*
//SYSTSIN DD *
/*
Break the command into two parts. End the first part with a hyphen.
EXAMPLE:
DSN(MY.DATA)
SPACE(10 5) TRACKS
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
ALLOCATE with the SHR or OLD keyword and the DDN keyword
DSN(library-name(member-name))
Connect a catalogued disk file/ dataset to a program for use as output, lengthening
(append) the file
Create a catalogued disk file/dataset, or library/ pds that has the same attributes
as another
space for the directory that will keep track of the members.
Remove the connection between a file and a program that has been established with
ALLOCATE and the DDN keyword
FREE DDN(ddname)
Copy a file
Display the dataset names, library names, and DDNAMES currently in use in your TSO
session.
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)
DELETE library(member-name)
or access(update)
Transmit a message to a TSO user. Cancel the message if the user can�t receive
messages or is logged off.
Transmit a message to a TSO user. Wait until the user is able to receive the
message.
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.
RECEIVE
LISTBC
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.
CALL �library-name(program-name)�
CALL *(program-name)
You may also be able to execute a program by simply putting its name in quotes:
"IEBGENER"
Execute a REXX program or CLIST that is not found on a library assigned to SYSEXEC
STATUS
CANCEL jobname(job-number)
Cancel a job that you have submitted and discard the printed output
Send JCL to MVS batch for processing I.E. spawn a detached process
HRECALL dataset/library
HBACKDS dataset/library
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
HQUERY
for example:
REXX Example:
Components are:
REXX Example:
VGET (variable-name)
REXX Example:
REXX Example:
SELECT PGM(program-name)
REXX Example:
Prevent an ISPF error from kicking you out of your session. (Hides diagnostic
messages)
REXX Example:
I will show this by an example. The line numbers on the left are for illustration
only.
2 TOP
4 SUBMIT
5 END NOSAVE
Explanations by line.
NONUM means that the editor should ignore line numbers, if any.
NUM instead means that the editor should assume line numbers
EMODE means that the editor should not go into "input mode"
Line 2.
TOP.
Position yourself at the top of data (important for the change command)
Line 3.
Line 4.
Send the data you are editing (if it's JCL) to MVS batch for processing
SUBMIT
Line 5.
END NOSAVE
END SAVE
Save what you are editing with a specific name other than the one you started with
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.
QUEUE "TOP"
QUEUE "SUBMIT
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.
http://www.touniteamerica.com/programming/justenuf.html
Gabe Gargiulo
Sometimes you need just enough information so that you can do something - it gets
you started when you don�t have time to learn everything. Get them at
http://www.touniteamerica.com/programming/justenuf.html
REXX Reference
All REXX verbs, keywords, and built-in functions as found in MVS, VM/CMS and OS/2.
How to use the REXX programming language on TSO. Information, ordering at:
http://www.touniteamerica.com/programming/rexx2.html
ISPF Services: Using the Dialogue Manager with REXX
How to create ISPF panels on TSO. Examples are in REXX. Information, ordering at:
http://www.touniteamerica.com/programming/dmbook.html
http://www.touniteamerica.com/programming/sqlbook.html
Ready to ship. Includes diskette containing all programs, data files and JCL.
http://www.touniteamerica.com/programming/cobolbook.html