The ADDRESS MQ GET command retrieves messages from the message queue using the FIFO retrieval method.
This command has the following format:
ADDRESS MQ GET OPTIONS([TRUNCATE] [KEEP] [CORRELID(corr)] [WAIT(time)] [CONVERT(ccsid)])
{CONHANDLE(varHCONN)}
{OBJHANDLE(varHOBJ)}
{DATA(varDATA)}
Specifies the processing options.
(Optional) Allows data to be truncated. If omitted, the GET operation fails when the data contains over 32,000 bytes.
(Optional) Causes messages to be kept on the queue. Keep is required when the queue is being browsed.
(Optional) Defines the correlation ID of the message to be returned.
Note: The CORRELID must be specified in hex format.
(Optional) Specifies the amount of time in seconds to wait for the message. If omitted, GET does not wait for any messages.
(Optional) Converts data to the host code page that is specified by the ccsid.
Defines the variable name that stores the connection handle.
Defines the variable name that stores the object handle.
Defines the variable name that stores the message.
Example: MQ GET
This example gets a message with a specific CorrelID, stored in variable mycorr:
ADDRESS MQ "GET OPTIONS(CORRELID("mycorr"))",
"CONHANDLE(hconn) OBJHANDLE(hobj) DATA(data2get)"
|
Copyright © 2014 CA Technologies.
All rights reserved.
|
|