z/OS TSO/E Programming Services
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Overview of the BSAM and QSAM macro instructions

z/OS TSO/E Programming Services
SA32-0973-00

Some of the BSAM and QSAM access method routines have been modified to provide special services under TSO/E; others provide the same function that is provided in a batch environment. Those BSAM and QSAM macro instructions that are not relevant to terminal I/O act as no-ops. All of the BSAM and QSAM macro instructions, when executed in the batch environment, provide the non-terminal functions as explained in z/OS DFSMS Macro Instructions for Data Sets.

You can issue the BSAM and QSAM macro instructions in 24-bit or 31-bit addressing mode but with these restrictions that do not apply to other environments:
  • The EODAD specification on the DCBE macro has no effect, so the end-of-data routine must be specified in the DCB macro and reside below the 16 MB line.
  • Certain ABEND issuances do not result in an IEC message or in calling the DCB ABEND exit routine.
  • The RMODE31=BUF operand in the DCBE macro has no effect, so the QSAM buffer pool, if any, is below the 16 MB line. Therefore, OPEN does not turn on the DCBEMD31 bit.
  • The large block interface, LBI, is not available.

Table 1 shows the functions performed by the BSAM and QSAM macro instructions when used for terminal I/O. Following the table are more detailed explanations of the GET, PUT, PUTX, READ, WRITE, and CHECK macro instructions.

Table 1. BSAM and QSAM macro functions under TSO/E
SAM macro instruction BSAM QSAM Terminal interpretation
BSP X X NOP
BUILD X X As in batch processing, the BUILD macro instruction causes a buffer pool to be constructed in a user-provided storage area.
CHECK X   Takes an EODAD exit after a READ EOF. NOP after a WRITE.
CLOSE X X The CLOSE macro instruction frees the control blocks built to handle I/O and deletes the loaded SAM terminal routines.
CNTRL X X NOP
DCBE X X Currently has no effect.
FEOV X X NOP
FREEBUF X   As in batch processing, the FREEBUF macro instruction causes the control program to return a buffer to the buffer pool assigned to the specified data control block.
FREEPOOL X X As in batch processing, the FREEPOOL macro instruction causes an area of virtual storage, previously assigned as a buffer pool for a specified data control block, to be released.
GET   X The GET macro instruction obtains data from the terminal.
GETBUF X   As in batch processing, the GETBUF macro instruction causes the control program to obtain a buffer from the buffer pool assigned to the specified data control block, and to return the address of the buffer in a designated register.
GETPOOL X X As in batch processing, the GETPOOL macro instruction causes a buffer pool to be constructed in a storage area provided by the control program.
NOTE X   NOP
OPEN X X The OPEN macro instruction loads the proper SAM terminal I/O routines and constructs the necessary control blocks.
POINT X   NOP, but TYPE=RELNEXT is not supported.
PRTOV X X NOP
PUT   X The PUT macro instruction routes data to the terminal.
PUTX   X The PUTX macro instruction routes data to the terminal.
READ X   The READ macro instruction obtains data from the terminal.
RELSE   X NOP
SETPRT X X NOP
TRUNC   X NOP, but BSAM is not supported.
WRITE X   The WRITE macro instruction routes data to the terminal.
Note: If QSAM is used for terminal I/O and the data set is defined with BLKSIZE=80 and RECFM=U, which is not recommended, each line will be truncated by 1 character. This byte (the last byte) is reserved for an attribute character.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014