Message Transmission

HULFT can transmit optional messages in parallel with file transfer from the Send system to the Receive system. The message transmitted can be used as 'strings to be output to the Send Log and the Receive Log,' 'replacement string for dynamic change in management information,' (for example, change the Receive File Name dynamically), 'replacement string to be passed to the startup job that uses environment variable substitutions' and so on.

For the message transmission between the hosts that uses different languages, refer to (6) Points to be Noted Regarding Message Transmission.

(1) Message Transmission Function

To transmit a message, specify a message parameter of the command that issues a request. For the execution of the Send File, specify a message parameter of the Send File command, while for the execution of the Send Request, specify a message parameter of the Send Request command, respectively.

Using environment variable allows you to change the values of management information dynamically. The message strings that you specified in the message parameters can be used as replacement strings for the following variable substitutions:

  • &MSG0 to &MSG5

    You can specify a message string of up to 50 bytes for each of the six substitutions from &MSG0 to &MSG5. These substitutions expand into the corresponding strings that you specify for message parameters from MSG0 to MSG5 in the Send File program or the Send Request program.

  • &MSGL0 to &MSGL1

    You can specify a message string of up to 200 bytes for each of the two substitutions &MSGL0 and &MSGL1. These substitutions expand into the corresponding strings that you specify for message parameters MSGL0 and MSGL1 in the Send File program or the Send Request program.

 

When a transmitter does not specify the message string that corresponds to the substitution used in target management information, the addressee handles the replacement string as a 0-byte message.

To assign replacement messages to substitutions, you must enable the Message Dynamic Parameter Specification (MSGDYNPARAM) of the System Environment Settings. For the System Environment Settings, refer to System Environment Settings.

= Remarks =

Regarding characters in the replacement messages, HULFT converts the code set according to the value that is specified for HULFT Character Set (HULCHARSET) of the System Environment Settings. For details, refer to (6) Points to be Noted Regarding Message Transmission.

Note

When HULFT assigns a message string that has been specified by a transmitter, an error occurs before file transfer if the replacement message causes one of the following situations:

  • Exceeding the maximum length that management information can accept

  • Generating unsuitable string for a file name on expansion into a Send file name

(2) Fields to which HULFT can assign message strings

The following list shows the fields and IDs to which HULFT can assign message strings that are specified by message parameters:

[Send Management Information]
  • Send File Name

  • Transfer Group ID

  • Pre-send Job ID

  • Successful Job ID

  • Format ID

  • Multi Format ID

[Receive Management Information]
  • Receive File Name

  • Transfer Group ID

  • Successful Job ID

[Job Information]
  • Argument to startup jobs

Note
  • For HULFT for Mainframe or HULFT for IBMi, each value or ID is registered in uppercase alphabetic characters. Specifying the messages in lowercase alphabetic characters remains the replacement messages as they are. Specify messages in uppercase alphabetic characters when using the replacement strings as values or IDs.

  • Specify one parameter for one message when using the message as startup job argument.

    Points to be noted when a message is used as startup job argument:

    • You cannot concatenate a substitution and a string as well as concatenate multiple substitutions (If concatenated, the message strings are not assigned).

      Incorrect:

      CALL library name/program name PARM(&MSGn&MSGn)

      CALL library name/program name PARM(character string &MSGn)

      CALL Library name/program name PARM(&MSGn string)

    • One message string is treated as one parameter.

      Correct:

      CALL library name/program name PARM(&MSGn)

      In above example, when a string 'ABC' 'XYZ' is specified for the MSGn parameter, the string is handled as one parameter value as in " 'ABC' 'XYZ' ," not as two parameter values as in 'ABC' and 'XYZ.'

(3) Flow of Message Assignment in Sending

Figure 2.18 Message Transmission (Sending)

1) Message transmission order from Send File command

The Send File is issued to the Send system from the Send File command with File ID and Message specified.

2) Modification of Send Management Information content

The Send system replaces the substitutions, which are registered as $MSG0 to $MSG5 and $MSGL0 to $MSGL1 in a record of the Send Management Information, with the 'strings' that are specified in the message parameters of the Send File command as explained in 1) . HULFT carries out sending using the values assigned.

3) Message transmission to host on receiving side

The Send system notifies the Message specified in the Send File command, to the Receive system before the data transfer starts.

4) Assignment of strings to environment variable substitutions used in the Post-send Job

The Send system assigns the message strings that are specified in the Send File program to environment variable substitutions ($MSG0 to $MSG5, and $MSGL0 to $MSGL1) so that Post-send Job can replace the values of the Job Information with the assigned the strings.

(4) Flow of Message Assignment in Receiving

Figure 2.19 Message Transmission (Receiving)

1) Acknowledgement of message notification from Send system

The Receive system receives the notification of the File ID and the Message from the Send system.

2) Modification to Receive Management Information content

The Receive system replaces '&MSG0' to '&MSG5' and '&MSGL0' to '&MSGL1' that are specified in the record of the File ID of the Receive Management Information, which has been transmitted from the Send system, with corresponding transmitted messages. HULFT carries out receiving according to assigned values.

3) Assignment of strings to environment variable substitutions used in the Post-receive Job

The Receive system assigns the message strings that are transmitted from the Send system to environment variable substitutions ($MSG0 to $MSG5, and $MSGL0 to $MSGL1) so that Post-receive Job can replace the values of the Job Information with the transmitted messages.

(5) Flow of Message Assignment in Send Request

Figure 2.20 Message Transmission (Send Request)

1) Message transmission order from Send Request command

The File ID and the Message are specified in the Send Request command. The Send Request command replaces the substitutions, which are registered as $MSG0 to $MSG5 and $MSGL0 to $MSGL1 in a record of the Receive Management Information, with corresponding messages.

2) Issue of Send Request

The Send Request command notifies specified Message along with the request issue to Send system.

3) Modification of Send Management Information content

The Send system replaces '&MSG0' to '&MSG5' and '&MSGL0' to '&MSGL1' that are specified in the record of the File ID of the Send Management Information, which has been transmitted from the Send Request command, with corresponding transmitted messages. HULFT carries out sending according to assigned values.

4) Message transmission to host on receiving side

The Send system notifies the Message notified from the Send Request command to the Receive system before the data transfer.

5) Acknowledge of message notification from Send system

The Receive system receives the notification of the File ID and the Message from the Send system.

6) Modification to Receive Management Information content

The Receive system replaces '&MSG0' to '&MSG5' and '&MSGL0' to '&MSGL1' that are specified in the record of the File ID of the Receive Management Information, which has been transmitted from the Send system, with corresponding transmitted messages. HULFT carries out receiving according to assigned values.

(6) Points to be Noted Regarding Message Transmission

Conversion of Character Codes

Regarding characters in the messages, HULFT converts the character codes according to the value that is specified for HULFT Character Set (HULCHARSET) of the System Environment Settings.

Points to be noted when specifying multi-byte characters in a message

  • If the used language differs between the local host and the destination host, the file transfer might ends unsuccessfully or the message might be substituted incorrectly when a multi-byte character is contained in a message.

  • If the destination host is either of the following, Japanese characters are the only multi-byte characters that can be used:

    • A version of HULFT lower than Ver.8.1.0 is installed on the destination host

    • The destination host is HULFT Ver.8.1.0 or higher and Use HULFT7 Comm. Mode is set to "Yes" on the destination host

Backward Compatibility

The conversion result differs from the result for HULFT for IBMi lower than Ver.8.1 according to the value that is specified for HULFT Character Set (HULCHARSET). Thus, a function to maintain compatibility is provided.

To produce the same result for conversion for single byte characters with HULFT for IBMi lower than Ver.8.1, specify 'I (Japan (Latin) Extended for IBM)' for the Character Set Options for Messages (CHARSETOPTMSG).

However, in HULFT for IBMi Ver.8.1 or higher, use of HULFT Character Set (HULCHARSET) is recommended.