Copyright © Cloud Software Group, Inc. All Rights Reserved
Copyright © Cloud Software Group, Inc. All Rights Reserved


Chapter 3 Tools : $SETENVCOMMAREA

$SETENVCOMMAREA
Passes data from TIBCO Object Service Broker into a calling environment that is not TIBCO Object Service Broker. (F)
Invocation
length = $SETENVCOMMAREA(value, segment#)
 
On return, contains the length remaining in the segment or COMMAREA after the function is performed. Its syntax is B (binary) with length 2.
The data to be passed. Its syntax can be C (fixed-length character string), V (variable-length character string), or W (double-byte character), with a length of either 8192 or 31744, depending on the data length.
Usage Notes
For CICS, the value for segment# is ignored.
For some CICS transactions the string of data that is passed in the COMMAREA consists of the session parameter string followed by user data.
For the SDK (C/C++), the maximum length for value applies even though much larger COMMAREAs are supported through the MAP table interface.
See Also
TIBCO Object Service Broker for z/OS External Environments or TIBCO Object Service Broker for Open Systems External Environments for information about using TIBCO Object Service Broker with external environments
TIBCO Object Service Broker Managing Data for information about MAP tables
Example
The following rule retrieves data from the EMPLOYEES table and returns the data to the COMMAREA:

 
RULE EDITOR ===> SCROLL: P
SETENV_1;
_ LOCAL MESSAGE, LENGTH;
_ ---------------------------------------------------------------------------
_ ------------------------------------------------------------+--------------
_ FORALL EMPLOYEES WHERE REGION = 'MIDWEST' : | 1
_ MESSAGE = MESSAGE || EMPLOYEES.LNAME ||';'; |
_ END; |
_ LENGTH = $SETENVCOMMAREA(MESSAGE, 1); | 2
_ ---------------------------------------------------------------------------

 

Copyright © Cloud Software Group, Inc. All Rights Reserved
Copyright © Cloud Software Group, Inc. All Rights Reserved