matthewstorey.co.uk
In this section Group datasets | ISPF commands | TSO commands

TSO commands

TSO commands can be entered on any command line, or in the command option of ISPF without the 'TSO' prefix.

A full list of these can be found in the IBM book:

Bookshelf: TSO/E (find bookshelves)

       Book: TSO/E Command Reference (find books)

TSO command Description
TSO ALTLIB DISPLAY Displays the list of CLIST and REXX exec datasets allocated.
TSO EXEC '<dataset(member)>' Executes the specified CLIST or REXX exec program.
TSO ISRDDN Displays the list of datasets allocated when you logged onto TSO.
TSO OGET <Unix file> <MVS dataset> [binary] Copies a Unix System Services file to an MVS dataset.
TSO OPUT <MVS dataset> <Unix file> [binary] Copies an MVS dataset (or member) to a Unix System Services file.
TSO PROFILE Displays your TSO profile settings.
TSO SEND '<message>' USER(<userid>) Sends the message to the specified userid, this will appear when the user presses enter.

The TRANSMIT command

The TRANSMIT and RECEIVE commands are very powerful in that they allow the transfer of datasets (either sequential or PDS) across different LPAR's and even physical mainframes to the same or different user. They can also be used to create an XMIT dataset, these are a sequential dataset that contain the contents of one or more PDS's.

Transferring datasets

To transfer the contains of a dataset, either sequential or PDS, use the command:

TSO TRANSMIT <machine>.<userid> DA('<dataset name>') [MEM()]

The 'machine.userid' is the LPAR and TSO userid you want to copy the data to. The 'DA' option specifies the dataset with the optional 'MEM' option specifing a particular member (if the dataset is a PDS).

For a user to receive any datasets sent to them, use the command:

TSO RECEIVE

After some TSO information prompts they will be asked to enter a location to store this dataset, at this prompt enter:

DA('<dataset name>')

The dataset will then be copied over. Depending on how TSO has been configured, if the destination dataset does not exist it may be automatically created or it will produce an error which means the dataset will need to be created before running a RECEIVE command.

Creating XMIT files

To create XMIT files from TSO use the command:

TSO TRANSMIT <machine>.<userid> DSNAME('<dataset name>') OUTDSNAME('<XMIT dataset>')

Where the XMIT dataset is a sequential dataset with the DCB attributes: LRECL=80, BLKSIZE=3120, and RECFM=FB.
You can then transfer the dataset in binary to another location.

To extracting the contents of an XMIT file, use the following variation of the RECEIVE command:

TSO RECEIVE INDSNAME('<XMIT dataset>')

After some TSO information prompts they will be asked to enter a location to store this dataset, at this prompt enter:

DA('<dataset name>')

The dataset will be copied over. Depending on how TSO has been configured, if the destination dataset does not exist it may be automatically created or it will produce an error which means the dataset will need to be created before running a RECEIVE command.

Back to top