z/OS DFSMS Using Data Sets
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Example: Issuing a SYNADAF Macro

z/OS DFSMS Using Data Sets
SC23-6855-00

The following example shows how a SYNAD routine specified through AMP can issue a SYNADAF macro without preliminaries. Registers 0 and 1 already contain what SYNADAF expects to find.
AMPSYN   CSECT
         USING     *,15               Register 15 contains the entry
                                      address to AMPSYN.
         SYNADAF   ACSMETH=QISAM      Either QISAM or BISAM can be
                                      specified.
         STM       14,12,12(13)
         BALR      7,0                Load address of next instruction
         USING     *,7
         L         15,132(1)          The address of the DCB is stored
                                      132 bytes into the SYNADAF message.
         L         14,128(1)          The address of the DECB is stored
                                      128 bytes into the SYNADAF message.
         TM        42(15),X'40'       Does the DCB indicate QISAM scan?
         BO        QISAM              Yes.
         TM        43(15),X'40'       Does the DCB indicate QISAM load?
         BO        QISAM              Yes.
BISAM    TM        24(14),X'10'       Does the DECB indicate an nonvalid
                                      BISAM request?
         BO        INVBISAM           Yes.
The routine might print the SYNADAF message or issue ABEND.
QISAM    TM        80(15),X'10'       Does the DCB indicate an nonvalid
                                      QISAM request?
         BO        INVQISAM           Yes.
The routine might print the SYNADAF message or issue ABEND.
INVBISAM EQU       *
INVQISAM EQU       *
         LM        14,12,12(13)
         DROP      7
         USING     AMPSYN,15
         SYNADRLS
         BR        14
         END       AMPSYN

When the processing program closes the data set, the interface issues VSAM PUT macros for ISAM PUT locate requests (in load mode), deletes the interface routines from virtual storage, frees virtual-storage space that was obtained for the interface, and gives control to VSAM.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014