SPAREA field descriptions

The RSP, Open ServerConnect, and MainframeConnect use the SPAREA by accessing the values from the SPAREA fields. The word Reserved in the descriptions indicates that the RSP cannot write to the field.

SPHEADER

SPHEADER contains the character string *SPAREA*. The character string serves as an eye catcher for locating the SPAREA in a dump. Reserved.

SPRESRVED

SPRESRVD contains values used by MainframeConnect to process commands. Reserved.

SPTRCOPT

SPTRCOPT controls the trace option. If the field contains 'Y' when an Open ServerConnect command is issued, trace records are written to the TSQ, CExxxxxx, where xxxxxx is the first six characters of the user ID.

SPSTATUS

SPSTATUS is used by an RSP or by Open ServerConnect to indicate the success or failure of processing.

When used by an RSP, it refers to RSP processing. When used by Open ServerConnect, it refers to processing on the remote database.

Valid values are:

SPCODE

The RSP uses SPCODE to supply user-defined error codes.

SPFORMAT

The RSP uses SPFORMAT to specify the data format when opening a data pipe. Valid values are: DB2, STD, and BIN.

SPMODE

The RSP uses SPMODE to specify the mode of the data pipe. Valid values are INPUT or OUTPUT.

SPRC

MainframeConnect uses SPRC to indicate the success or failure of an RSP command. Valid return codes are:

SPFROM

The RSP uses SPFROM to specify the address of the STD or BIN format data record that it writes to the output pipe. See PUTPIPE for an example of using SPFROM.

SPINTO

The RSP uses SPINTO to specify the address of a storage area where the STD or BIN format data record read from the input pipe can be placed. See GETPIPE for an example of using SPINTO.

SPSQLDA

The RSP and MainframeConnect uses SPSQLDA to specify the address of an SQLDA that describes the data records. This field is only used for DB2 format output data pipes. The RSP must build the SQLDA and supply this pointer when it opens the pipe.

For information on SQLDA structure, see the IBM SQL reference guide for DB2. A sample SQLDA definition is provided in Appendix B, “MODELRSP DB2 Output Pipe Sample RSP.”

SPVARTXT

SPVARTXT contains the pointer of the variable text that the client application may optionally send to the RSP. This field contains null.

SPVARTAB

SPVARTAB contains the pointer of the variable substitution table, which is created if the client sends keyword variables (that is, &KEYWORD=value format). If keyword variables are not sent, this field contains null.

SPMAXLEN

The RSP uses SPMAXLEN to specify the maximum record length for records read from or written to a STD or BIN format pipe. See “Using data pipes” for more information.

SPRECLEN

The RSP and MainframeConnect uses SPRECLEN to specify the length of records read from or written to a STD or BIN format data pipe.

For output pipes, the RSP must set this field to the length of the record it writes (unless it is writing fixed-length records of the same size as SPMAXLEN). For input pipes, Open ServerConnect sets this field to the length of the record it is sending to the RSP.

For more information, see “SPMAXLEN and SPRECLEN”. Also see “Using data pipes” for more information.

SPVARLEN

SPVARLEN contains the length of the variable text that the client may optionally send to the RSP. This field contains zeros.

SPPREFIX

Not used.

SPMSG

The RSP uses SPMSG to place message text it sends the client application with a MESSAGE command.