SubUserData (MQCHARV)

This specifies the subscription user data. The data provided on the subscription in this field will be included as the MQSubUserData message property of every publication sent to this subscription.

The maximum length of SubUserData is 10240.

If SubUserData is specified incorrectly, according to the description of how to use the MQCHARV structure, or if it exceeds the maximum length, the call fails with reason code MQRC_SUB_USER_DATA_ERROR.

This is an input field. The initial values of the fields in this structure are the same as those in the MQCHARV structure.

If altering an existing subscription using the MQSO_ALTER option, the subscription user data can be changed.

This variable length field is returned on output from an MQSUB call using the MQSO_RESUME option, if a buffer is provided and there is a positive buffer length in VSBufLen. If no buffer is provided on the call, only the length of the subscription user date is returned in the VSLength field of the MQCHARV. If the buffer provided is smaller than the space required to return the field, only VSBufLen bytes are returned in the provided buffer.

Parent topic: Fields for MQSD