IBM Support

QtmsCreateSendEmail fails with TCP5308 "CCSID <some big number> not supported" when more than one receipient is set.

Question & Answer


Question

Why is QtmsCreateSendEmail failing with TCP5308 when more than one receipient is set?

Cause

Description of RCPT0100 Format is misleading

Answer

The description of RCPT0100 Format is sometimes misinterpreted:

Offset

TypeField
Dec
Hex
0
0
Binary(4)Input CCSID
4
4
Binary(4)Recipient Type
8
8
Binary(4)Offset to recipient address
12
C
Binary(4)Length of recipient address

Char(*)Recipient address

This looks like the recipient address of each recipient is stored after each group of the 4 fixed length integers.

However the Recipient array must be defined as an array of

Type Field
Binary(4) Input CCSID
Binary(4) Recipient Type
Binary(4) Offset to recipient address
Binary(4) Length of recipient address

followed by only one char(*) value initialized with all the recipient
addresses.

So this is an example with two recipients:
Number of recipients = 2
Recipient array:
Offset
Field Contents
0
Input CCSID 10 = current job CCSID
4
Recipient Type 10 = Normal Recipient
8
Offset to recipient address 132 (*1)
12
Length of recipient address 116
16
Input CCSID 20 = current job CCSID
20
Recipient Type 21 = Carbon Copy
24
Offset to recipient address 248 (*2)
28
Length of recipient address 227
(*1) 32
Address 1ibmkc@us.ibm.com
(*2) 48
Address 2ibmi_support@ecurep.ibm.com

The variable length addresses can be in any sequence as long as offset and length are correctly set.

[{"Product":{"code":"SWG60","label":"IBM i"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"Communications-TCP","Platform":[{"code":"PF012","label":"IBM i"}],"Version":"Version Independent","Edition":"","Line of Business":{"code":"LOB57","label":"Power"}},{"Product":{"code":"SWG60","label":"IBM i"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":" ","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB57","label":"Power"}}]

Document Information

Modified date:
18 December 2019

UID

nas8N1021759