If the codepage of your client program is different from the codepage used by the CICS® user program, your messages need to be converted.
The BRIH, all BRIV vector headers and RETRIEVE data can be converted using the CICS conversion program DFHCCNV. See the CICS Family: Communicating from CICS on System/390® manual for information about the data conversion process.
DFHCCNV uses the DFHCNV table to determine the required conversions. You need to supply entries in this table for each resource that requires conversion. See the CICS Family: Communicating from CICS on System/390 manual .
In your DFHCNV, you should include:
COPY DFHBRCTD
If you are using codepages other than the defaults, that is, other than 437 for the client and 037 for the server, then you must ensure that the correct codepage conversion is applied to DFHBRCTD. You can do this by coding SRVERCP and CLINTCP parameters on the DFHCNV TYPE=INITIAL statement. The COPY DFHBRCTD statement should follow DFHCNV TYPE=INITIAL.
If the application programs run using the same codepages as those specified on the TYPE=INITIAL statement, then the TYPE=ENTRY statements do not need to specify the codepages.
If an application program, or programs, need to use different codepages, then the new values must be specified on the appropriate TYPE=ENTRY statements.
Build DFHCNV as described in the CICS Family: Communicating from CICS on System/390 manual . This will convert the BRIH and BRIV vector headers using the codepages described in your conversion template.
Figure 11 shows an example of a DFHCNV for a CICS region using codepage 939 for the server programs and codepage 943 for most of the clients.
The COPY DFHBRCTD statement follows the DFHCNV TYPE=INITIAL statement, so it will use 939 and 943. This is used in the conversion of BRIHs.
PROG1 uses the same codepages, but PROG2 uses client codepage 932 instead of 939. In order to achieve this, the TYPE=ENTRY statement for PROG2 contains overrides for the client and server codepages.
DFHCNV TITLE 'EXAMPLE DFHCNV CONVERSION TABLE'
*
DFHCNV TYPE=INITIAL,SRVERCP=939,CLINTCP=943
*
COPY DFHBRCTD
*
DFHCNV TYPE=ENTRY,RTYPE=PC,RNAME=PROG1
DFHCNV TYPE=SELECT,OPTION=DEFAULT
DFHCNV TYPE=FIELD,OFFSET=0,DATATYP=CHARACTER,DATALEN=10018, *
LAST=YES
*
DFHCNV TYPE=ENTRY,RTYPE=PC,RNAME=PROG2, *
SRVERCP=939,CLINTCP=932
DFHCNV TYPE=SELECT,OPTION=DEFAULT
DFHCNV TYPE=FIELD,OFFSET=0,DATATYP=CHARACTER,DATALEN=500, *
LAST=YES
*
DFHCNV TYPE=FINAL
END
RETRIEVE data is converted using the conversion template for the user transaction. You should provide a DFHCNV entry with RTYPE=IC RNAME=user tranid.
User data following each BRIV (including the ADSD, but excluding RETRIEVE data) is converted in the AOR using the GCHARS and GCODES values defined for the facilitylike terminal that was used as a template to build the bridge facility. You should define these values appropriately for your client program, and specify the facilitylike name in your Link3270 call if you are not using the default. The client codepage must be specified in value 2 of CGCSGID in the AOR as well as in the DFHCNV conversion table in the router region..
The codepage conversion for user data is based on the codepage conversion for EPI emulation. Refer to in CICS Family: Communicating from CICS on System/390 for the correct values for the CGCSGID field in the TYPETERM definition associated with the facilitylike.
CGCSGID values 1 and 2 can be retrieved by an application program using EXEC CICS ASSIGN GCHARS and EXEC CICS ASSIGN GCODES respectively.