When you issue a RECEIVE MAP command, BMS needs storage in which to build the input map structure. You can provide this space yourself, either in the working storage of your program or with a CICS® GETMAIN. These are the same choices you have for allocating storage in which to build an output map, and you use them the same way (see Acquiring and defining storage for the maps for details and examples). For either, you code the INTO option on your RECEIVE command, naming the variable into which the formatted input is to be placed. For our "quick update", for example, the required command is:
EXEC CICS RECEIVE MAP('QUPMAP') MAPSET('QUPSET')
INTO(QUPMAPI) END-EXEC.
Usually, the receiving variable is the area defined by the symbolic input map, to which BMS assigns the map name suffixed by the letter "I", as shown above. You can specify some other variable if you wish, however.
For input operations, you have a third choice for acquiring storage. If you code the SET option, BMS acquires the storage for you at the time of the RECEIVE command and returns the address in the pointer variable named in the SET option. So we could have coded the RECEIVE MAP command in "quick update" like this:
LINKAGE SECTION.
...
01 QUPMAP COPY QUPMAP.
...
PROCEDURE DIVISION.
...
EXEC CICS RECEIVE MAP('QUPMAP') MAPSET('QUPSET')
SET(ADDRESS OF QUPMAPI) END-EXEC.
...
Storage obtained in this way remains until task end unless you issue a FREEMAIN to release it (see Storage control).
[[ Contents Previous Page | Next Page Index ]]