Outcome of request fields

Admin_RC field
This byte field contains the overall outcome of the request. This is a field of type int that is set to one of:
MQeAdminMsg.RC_Success
The action completed successfully.
MQeAdminMsg.RC_Failed
The request failed completely.
MQeAdminMsg.RC_Mixed
The request was partially successful. A mixed return code could result if a request is made to update four attributes of a queue and three succeed and one fails.
Admin_Reason
A Unicode field containing the overall reason for the failure in the case of Mixed and Failed.
Admin_Parms
An MQeFields object containing a field for each characteristics of the managed resource.
Admin_Errors
An MQeFields object containing one field for each update that failed. Each entry contained in the Admin_Errors field is of type ASCII or asciiArray.
The following methods are available for getting some of the reply fields:
Table 1. Getting administration reply fields
Administration field Field type Get method
Admin_RC int int getAction()
Admin_Reason Unicode String getReason()
Admin_Parms MQeFields MQeFields getOutputFields()
Admin_Errors MQeFields MQeFields getErrorFields()

Depending on the action performed, the only fields of interest may be the return code and reason. This is the case for delete. For other actions such as inquire, more details may be required in the reply message. For instance, if an inquire request is made for fields Queue_Description and Queue_FileDesc, the resultant MQeFields object would contain the values for the actual queue in these two fields.

The following table shows the Admin_Parms fields of a request message and a reply message for an inquire on several parameters of a queue:
Table 2. Enquiring on queue parameters
Admin_Parms field name Request message Reply message
Type Value Type Value
Admin_Name ASCII "TestQ" ASCII "TestQ"
Queue_QMgrName ASCII "ExampleQM" ASCII "ExampleQM"
Queue_Description Unicode null Unicode "A test queue"
Queue_FileDesc ASCII null ASCII "c:\queues\"

For actions where no additional data is expected on the reply, the Admin_Parms field in the reply matches that of the request message. This is the case for the create and update actions.

Some actions, such as create and update, may request that several characteristic of a managed resource be set or updated. In this case, it is possible for a return code of RC_Mixed to be received. Additional details indicating why each update failed are available from the Admin_Errors field. The following table shows an example of the Admin_Parms field for a request to update a queue and the resultant Admin_Errors field:
Table 3. Request and reply message to update a queue
Field name Request message Reply message
Type Value Type Value
Admin_Parms field
Admin_Name ASCII "TestQ" ASCII "TestQ"
Queue_QMgrName ASCII "ExampleQM" ASCII "ExampleQM"
Queue_Description Unicode null Unicode "ExampleQM" "A new description"
Queue_FileDesc ASCII null Unicode "D:\queues"
Admin_Errors field
Queue_FileDesc n/a n/a ASCII "Code=4;com.ibm. mqe.MQeException: wrong field type"

For fields where the update or set is successful there is no entry in the Admin_Errors field.

A detailed description of each error is returned in an ASCII string. The value of the error string is the exception that occurred when the set or update was attempted. If the exception was an MQeException, the actual exception code is returned along with the toString representation of the exception. So, for an MQeException, the format of the value is:
"Code=nnnn;toString representation of the exception"

Terms of use | WebSphere software

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