Previous Topic: ADDRESS MQ Command Format

Next Topic: MQ OPEN—Open a Queue

MQ CONNECT—Provide Queue Manager Connection

The ADDRESS MQ Connect command lets you specify a specific Queue Manager connection.

This command has the following format:

ADDRESS MQ CONNECT {QMGR(name)} {CONHANDLE(varHCONN)}
QMGR

Specifies the queue manager name to which you want to connect. The name can be up to 48 bytes and is case sensitive.

CONHANDLE(varHCONN)

Specifies the variable name to store the connection handle.

Example: MQ Connect

This example connects to the queue manager CSQ7:

ADDRESS MQ "CONNECT QMGR(CSQ7) CONHANDLE(hconn)"