Module 8: CICS Program and Data Passing
COMMAREA
What is a COMMAREA
- COMMAREA is short for Communication Area.
- It is a data area used to pass data from one CICS program to another.
- You name it on the LINK, XCTL or RETURN command with the COMMAREA option.
- The program that receives it must define a field named DFHCOMMAREA in its Linkage Section.
- CICS puts the length of the COMMAREA in the EIBCALEN field (S9(4) COMP).
- Always check EIBCALEN before using DFHCOMMAREA.
How a program receives a COMMAREA
How a program sends a COMMAREA
- Use the COMMAREA(data-name) option on LINK, XCTL or RETURN.
- Always give the LENGTH option with the number of bytes being passed.
- Both the sending and receiving programs must agree on the layout.
- The LENGTH you pass must not be larger than the DFHCOMMAREA defined by the receiver.
MainframeBug Assistant