CHARCOUNTTYPES(*UTF8 *UTF16 *JOBRUN *MIXEDEBCDIC *MIXEDASCII)

The Control keyword CHARCOUNTTYPES specifies the types of data that are processed by characters rather than by bytes or double bytes when CHARCOUNT NATURAL mode is in effect. See Processing string data by the natural size of each character.

If this keyword is not specified, Control keyword CHARCOUNT(*NATURAL), File keyword CHARCOUNT(*NATURAL) and directive /CHARCOUNT NATURAL cannot be specified in the module.

*UTF8
Specify *UTF8 if your module might work with UTF-8 data which has characters of different lengths. For example, the UTF-8 character 'a' has one byte, and the UTF-8 character 'á' has two bytes.
*UTF16
Specify *UTF16 if your module might work with UTF-16 data which has some 4-byte characters.
*JOBRUN
Specify *JOBRUN if your job CCSID might support mixed SBCS and DBCS data, and the RPG variables in your module defined to have the job CCSID might contain some DBCS data.
Note: If you specify Control keyword CCSID(*CHAR:*JOBRUN), RPG variables defined without the CCSID keyword are defined to have the job CCSID.
*MIXEDEBCDIC
Specify *MIXEDEBCDIC if your module might work with EBCDIC data which supports both SBCS and DBCS characters. This includes data defined with CCSID(*JOBRUNMIX) and data defined with a mixed SBCS/DBCS CCSID such as 937.
Warning: By default, RPG assumes that alphanumeric data is in the mixed EBCDIC CCSID related to the job CCSID. If you choose this option and CHARCOUNT NATURAL mode is in effect, extra processing is done when this data is assigned, or used for a string built-in function.

To correct this assumption, specify Control keyword CCSID(*CHAR:*JOBRUN). If you want CHARCOUNT NATURAL processing for the case where the job CCSID supports both SBCS and DBCS data, specify *JOBRUN for the CHARCOUNTTYPES keyword.

*MIXEDASCII
Specify *ASCII if your module might work with ASCII data which supports both SBCS and DBCS characters.