Print Message sample on z/OS

The Print Message sample demonstrates how to remove a message from a queue and print the data in the message, together with all the fields of its message descriptor. It can, optionally, display all of the message properties associated with each message.

By removing comment characters from two lines in the source module, we can change the program so that it browses, rather than removes, the messages on a queue. This program can usefully be used for diagnosing problems with an application that is putting messages on a queue.

The application uses these MQI calls:

The program is delivered in the C language. The application runs in the batch environment. See Table 3 for the batch application. Parent topic: Features demonstrated in the sample applications for z/OS