|
High-Level Language SWSExciDplReq (SWCPED) FunctionRelated Topics
SWSExciDplReq is the Web Server API function used to disconnect a CICS EXCI Connection. In order to execute a CICS Transaction using this interface, you will need to execute the following API calls in the sequence listed below
SWCPED Call ArgumentsThe SWSExciDplReq (SWCPED) function arguments are described in the table which follows. All parameters are required.
Return ValuesSWSExciDplReq always sets a signed numeric return code value. Possible values are:
PL/I Example%INCLUDE DFHXCPLL %INCLUDE DFHXCRCL %INCLUDE SPCPHD . . . . DCL STMTHDL FIXED BIN(31); /* Statement Handle */ DCL USER_TOKEN FIXED BIN(31); /* User Token */ DCL PIPE_TOKEN FIXED BIN(31); /* User Token */ DCL CONNECTION_NAME CHAR(4); /* Connection Name */ DCL RC FIXED BIN(31); /* RETURN CODE */ CONNECTION_NAME = 'EWST' /* SET name */ CALL SWSEXCIDPLREQ(STMTHDL /* STATEMENT HANDLE */ SWS_CICS_TYPE_EXCI, /* CONNECTION TYPE */ CONNECTION_NAME, /* CONNECTION NAME */ TRANS_ID, /* TRANSACTION ID */ EXCI_RETURN_CODE, /* CICS EXCI RETURN AREA */ PROGRAM_NAME, /* PROGRAM NAME */ COMMAREA, /* COMMAREA */ SIZEOF(COMMAREA), /* COMMAREA LENGTH */ STRLEN(COMMAREA), /* COMMAREA LENGTH */ NULL, /* UNIT OF WORK ID AREA */ USER_ID, /* USER ID */ USERTOKEN, /* USER TOKEN */ PIPETOKEN, /* PIPE TOKEN */ EXCI_DPL_RETAREA) /* DPL RETURN CODE AREA */ RC = PLIRETV(); /* GET RETURN CODE */ IF RC ^= SWS_SUCCESS THEN /* EXIT PROGRAM IF BAD RC */ EXIT;
C ExampleNOTE: The Neon Header file must be included after the CICS EXCI headers. #include "dfhxcplh.h" /* CICS Return Area header */ #include "dfhxcrch.h" /* CICS Response Codes */ #include "sccphd.h" /* Neon headers */ exci_return_code exciRET; /* cics exci return area */ exci_dpl_retarea exciDPL; /* cics exci DPL return area */ . . . . long RC; /* return code */ long stmtHDL; /* statement handle */ long userTOKEN; /* user token */ long pipeTOKEN; /* user token */ char commarea[32704]; /* Connection Name */ char connection_name[] = "EWST"; /* Connection Name */ char trans_id[] = "EXCI"; /* Transaction id */ char user_id[] = " "; /* userid */ CALL SWSExciDplReq(stmtHDL, /* statement handle */ SWS_CICS_TYPE_EXCI, /* connection type */ connection_name, /* connection name */ trans_id, /* transaction id */ exciRET, /* cics exci return area */ program_name, /* program name */ commarea, /* commarea */ sizeof(commarea), /* commarea length */ strlen(commarea), /* commarea length */ NULL, /* unit of work id area */ user_id, /* user id */ userTOKEN, /* user token */ pipeTOKEN, /* pipe token */ exciDPL) /* DPL Return Code Area */ if (rc ^= SWS_SUCCESS) return rc;
COBOL ExampleCOPY DFHXCPLO. CICS EXCI Return Areas COPY DFHXCRCO. CICS EXCI Response Codes COPY SBCPHD. Neon Copybook . . . . 77 CONNECTION-NAME PIC X(4) VALUE IS 'EWST'. 77 TRANS-ID PIC X(4) VALUE IS 'EXCI'. 77 PROGRAM-NAME PIC X(8) VALUE IS 'DFH$AXCS'. 77 FILL-8 PIC X(8) VALUE IS SPACES. 77 STATEMENT-HANDLE USAGE IS POINTER. 77 USER-TOKEN PIC S9(5) COMP VALUE IS ZERO. 77 PIPE-TOKEN PIC S9(5) COMP VALUE IS ZERO. 77 CICS-BUFFER-INPUT-LENGTH PIC S9(5) COMP VALUE IS ZERO. 77 CICS-BUFFER-COMMAREA-LENGTH PIC S9(5) COMP VALUE IS ZERO. 01 UOWID USAGE IS POINTER. 01 CICSBUFFER. 05 CICS-BUFFER-COMMAREA. 10 CICS-BUFFER-COMMAREA-RETURNCD PIC S9(5) COMP. 10 CICS-BUFFER-COMMAREA-FILENAME PIC X(8). 10 CICS-BUFFER-COMMAREA-RIDFIELD PIC X(6). 10 CICS-BUFFER-COMMAREA-RECORD PIC X(512). . . . . SET SWS-CICS-TYPE-EXCI TO TRUE. CALL 'SWCPED' USING STATEMENT-HANDLE SWS-CICS-TYPE CONNECTION-NAME TRANS-ID EXCI-RETURN-CODE PROGRAM-NAME CICS-BUFFER-COMMAREA CICS-BUFFER-COMMAREA-LENGTH CICS-BUFFER-INPUT-LENGTH UOWID FILL-8 USER-TOKEN PIPE-TOKEN EXCI-DPL-RETAREA. MOVE RETURN-CODE TO WS-SWSAPI-RETURN-CODE. IF NOT SWS-SUCCESS GOBACK. |