IBM Support

CICS WEB SEND has a x'85' character being appended

Question & Answer


Question

We use the CICS WEB SEND statement with the DOCTOKEN option. When the SEND occurs it is attaching a x'85' to the end of the body which is translating to a ? on the end users server. This causes the service to reject the request.

It does not put the extra character if the document is stored in a PDS just in Unix System Services.
When I look in memory of the transaction I do see a x'15' for the last character that I guess gets translated to the x'85'.

What do I need to change to get this to work?

Answer

It appears that the x'15' is being appended to each line by the file read call that CICS makes. The x'15' (newline) character is not valid whitespace in XML. The XML document says it is in UTF-8 but the conversion before sending is only using ISO-8859-1 which means that the newline ends up as x'85' (which is the ISO-8859-1 codepoint and not the UTF-8 codepoint). This also makes the document invalid.

If you have the setting APPENDCRLF(YES) on the DOCTEMPLATE definition, this will cause the x'15' to be converted to x'25' when the file is read. The x'25' (linefeed) character is valid whitespace so the XML document would then parse successfully.

[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SSGMGV","label":"CICS Transaction Server"},"Platform":[{"code":"PF035","label":"z\/OS"}],"Component":"Web Services","Version":"","Line of Business":{"code":"LOB35","label":"Mainframe SW"}}]

Product Synonym

CICS/TS CICSTS CICS TS CICS Transaction Server

Document Information

Modified date:
26 February 2020

UID

dwa1419340