Message filters

Introduction to MQe message filters

Filters allow MQe to perform powerful message searches. Most of the major queue manager operations support the use of filters. You can create filters using MQeFields.

Using a filter, for example in a getMessage() call, causes an application to return the first available message that contains the same fields and values as the filter. The following examples create a filter that obtains the first message with a message id of "1234":
Java™
MQeFields filter = new MQeFields();
filter.putArrayOfByte( MQe.Msg_MsgID, 
        MQe.AsciiToByte( "1234" ) );
C
rc = mqeFields_putArrayOfByte(hMsg, &exceptBlock, MQE_MSG_MSGID, pByteArray, sizeByteArray);

You can use this filter as an input parameter to various API calls, for example getMessage.


Terms of use | WebSphere software

(c) Copyright IBM Corporation 2004, 2005. All rights reserved.