MQCFH - PCF header

Use this page to view the structure of an MQCFH header and the declarations for the following programming languages: C, COBOL, PL/I, RPG/ILE, S/390 assembler, and Visual Basic

The MQCFH structure describes the information that is present at the start of the message data of a monitoring message. Following the links to the declarations is a description of the fields making up the MQCFH structure:

    Type

    Description: Structure type This indicates the content of the message.
    Data type: MQLONG.
    Values:

      MQCFT_ACCOUNTING
      Message is an accounting message.

      MQCFT_EVENT
      Message is reporting an event.

      MQCFT_REPORT
      Message is an activity report.

      MQCFT_RESPONSE
      Message is a response to a command.

      MQCFT_STATISTICS
      Message is a statistics message.

      MQCFT_TRACE_ROUTE
      Message is a trace-route message.

    StrucLength

    Description: This is the length in bytes of the MQCFH structure
    Data type: MQLONG.
    Value:

      MQCFH_STRUC_LENGTH
      Length of command format header structure.

    Version

    Description: Structure version number.
    Data type: MQLONG.
    Value:

      MQCFH_VERSION_1
      Version number for all events except configuration and command events.

      MQCFH_VERSION_2
      Version number for configuration events.

      MQCFH_VERSION_3
      Version number for command events, activity reports, trace-route messages, accounting and statistics messages.

    Command

    Description: Specifies the category of the message.
    Data type: MQLONG.
    Value: Refer to the Command values in the following structure descriptions:

    MsgSeqNumber

    Description: Message sequence number. This is the sequence number of the message within a set of related messages.
    Data type: MQLONG.

    Control

    Description: Control options.
    Data type: MQLONG.
    Value:

      MQCFC_LAST
      Last message in the set.

      MQCFC_NOT_LAST
      Not the last message in the set.

    CompCode

    Description: Completion code.
    Data type: MQLONG.
    Value:

      MQCC_OK
      Events reporting OK condition, activity reports, trace-route messages, accounting messages, or statistics messages.

      MQCC_WARNING
      Event reporting warning condition.

    Reason

    Description: Reason code qualifying completion code.
    Data type: MQLONG.
    Value: For event messages:

      MQRC_*
      Dependent on the event being reported. Note: Events with the same reason code are further identified by the ReasonQualifier parameter in the event data.

    For activity reports, trace-route messages, accounting messages, and statistics messages:

      MQRC_NONE

    ParameterCount

    Description: Count of parameter structures. This is the number of parameter structures that follow the MQCFH structure.
    Data type: MQLONG.
    Value: 0 or greater.


C language declaration

typedef struct tagMQCFH {
  MQLONG  Type;            /* Structure type */
  MQLONG  StrucLength;     /* Structure length */
  MQLONG  Version;         /* Structure version number */
  MQLONG  Command;         /* Command identifier */
  MQLONG  MsgSeqNumber;    /* Message sequence number */
  MQLONG  Control;         /* Control options */
  MQLONG  CompCode;        /* Completion code */
  MQLONG  Reason;          /* Reason code qualifying completion code */
  MQLONG  ParameterCount;  /* Count of parameter structures */
 } MQCFH;


COBOL language declaration

**   MQCFH structure
  10 MQCFH.
**    Structure type
   15 MQCFH-TYPE           PIC S9(9) BINARY.
**    Structure length
   15 MQCFH-STRUCLENGTH    PIC S9(9) BINARY.
**    Structure version number
   15 MQCFH-VERSION        PIC S9(9) BINARY.
**    Command identifier
   15 MQCFH-COMMAND        PIC S9(9) BINARY.
**    Message sequence number
   15 MQCFH-MSGSEQNUMBER   PIC S9(9) BINARY.
**    Control options
   15 MQCFH-CONTROL        PIC S9(9) BINARY.
**    Completion code
   15 MQCFH-COMPCODE       PIC S9(9) BINARY.
**    Reason code qualifying completion code
   15 MQCFH-REASON         PIC S9(9) BINARY.
**    Count of parameter structures
   15 MQCFH-PARAMETERCOUNT PIC S9(9) BINARY.


PL/I language declaration ( z/OS and Windows )

dcl
 1 MQCFH based,
  3 Type           fixed bin(31), /* Structure type */
  3 StrucLength    fixed bin(31), /* Structure length */
  3 Version        fixed bin(31), /* Structure version number */
  3 Command        fixed bin(31), /* Command identifier */
  3 MsgSeqNumber   fixed bin(31), /* Message sequence number */
  3 Control        fixed bin(31), /* Control options */
  3 CompCode       fixed bin(31), /* Completion code */
  3 Reason         fixed bin(31), /* Reason code qualifying completion
                                     code */
  3 ParameterCount fixed bin(31); /* Count of parameter structures */


RPG language declaration ( IBM i only)

D*..1....:....2....:....3....:....4....:....5....:....6....:....7..
D* MQCFH Structure
D*
D* Structure type
D  FHTYP                  1      4I 0 INZ(1)
D* Structure length
D  FHLEN                  5      8I 0 INZ(36)
D* Structure version number
D  FHVER                  9     12I 0 INZ(1)
D* Command identifier
D  FHCMD                 13     16I 0 INZ(0)
D* Message sequence number
D  FHSEQ                 17     20I 0 INZ(1)
D* Control options
D  FHCTL                 21     24I 0 INZ(1)
D* Completion code
D  FHCMP                 25     28I 0 INZ(0)
D* Reason code qualifying completion code
D  FHREA                 29     32I 0 INZ(0)
D* Count of parameter structures
D  FHCNT                 33     36I 0 INZ(0)
D*


S/390 assembler language declaration ( z/OS only)

MQCFH                          DSECT
MQCFH_TYPE                     DS   F        Structure type
MQCFH_STRUCLENGTH              DS   F        Structure length
MQCFH_VERSION                  DS   F        Structure version number
MQCFH_COMMAND                  DS   F        Command identifier
MQCFH_MSGSEQNUMBER             DS   F        Message sequence number
MQCFH_CONTROL                  DS   F        Control options
MQCFH_COMPCODE                 DS   F        Completion code
MQCFH_REASON                   DS   F        Reason code qualifying
*                                            completion code
MQCFH_PARAMETERCOUNT           DS   F        Count of parameter
*                                            structures
MQCFH_LENGTH                   EQU  *-MQCFH  Length of structure
                               ORG  MQCFH
MQCFH_AREA                     DS   CL(MQCFH_LENGTH)


Visual Basic language declaration ( Windows only)

Type MQCFH
  Type As Long            'Structure type
  StrucLength As Long     'Structure length
  Version As Long         'Structure version number
  Command As Long         'Command identifier
  MsgSeqNumber As Long    'Message sequence number
  Control As Long         'Control options
  CompCode As Long        'Completion code
  Reason As Long          'Reason code qualifying completion code
  ParameterCount As Long  'Count of parameter structures
End Type
Parent topic: Structure data types