I'm not able to fix an issue about MQ queue.
My procedures run on Host environment and I have to receive via MQ the communications sent by a procedure running on a Unix Machine.
The process of the sender put the record on MQ queue using JSP and when I get it on the Host Environment the record is not manageable because the characters are not clear.
I tried to set the MQGMO_CONVERT on the parameter GetMsgOpts in order to convert the record before to make it available on the Host Environment.
But when I get the record, the MQ program fails to process an MQ API call. MQ notifies the program of the failure, by returning a completion code (MQCC) filled with “1”, and a reason code filled with “2116”.
The explanation of this code is:
X'844' Integer encoding specified by receiver not recognized.
On an MQGET call with the MQGMO_CONVERT option included in the GetMsgOpts parameter, the Encoding value in the MsgDesc parameter specifies an integer encoding that is not recognized.
The message data is returned unconverted, the values of the CodedCharSetId and Encoding fields in the MsgDesc parameter are set to those of the message being retrieved, and the call completes with MQCC_WARNING.
Corrective action: Check the integer encoding that was specified.
If this is correct, check that it is one for which queue manager conversion is supported. If queue manager conversion is not supported for the required integer encoding, conversion must be carried out by the application.
By using some displays on the program I checked the Encoding value is filled with 0311 (hexadecimal) and the Q manager used on my Host Environment manages this kind of Encoding.
So, I don’t understand why the MQ Processes can’t make the conversion.
May be the using of JSP by the sender is incompatible with the conversion request invoked on the Host Environment?
Or better, when the sender uses JSP is possible to connect via MQ Departmental Environments only?
Pinned topic MQ - Error 2116 during an MQ get on Host Environment
Answered question This question has been answered.
Unanswered question This question has not been answered yet.
Updated on 2012-12-12T08:47:54Z at 2012-12-12T08:47:54Z by SystemAdmin
Re: MQ - Error 2116 during an MQ get on Host Environment2012-12-05T11:26:27ZThis is the accepted answer. This is the accepted answer.Hi there,
Sometimes using a sample can help to rule out any application errors. My suggestion would be to use something like the q program (SupportPac MA01) to browse the message in two ways.
First without using MQGMO_CONVERT to see how the JSP application made the message:
q -m qmgr-name -iq-name -ddD2
where -d (display) d (MQMD after MQGET) D (MQMD before MQGET) 2 (2 level of MQMD detail)
Second by using MQGMO_CONVERT to attempt to replicate the error your own application saw:
q -m qmgr-name -iq-name -ddD2 -c0
where -c0 does a MQGMO_CONVERT to MQCCSI_QMGR (i.e. the default)
In each case printing out the MQMD before and after the MQGET shows exactly the CodedCharSetId and Encoding fields in the MQMD to show us exactly what is going on.
Each case will show you output something like this:-
MQMD before MQGET Message Descriptor (MQMD) Version :1 Report :00000000 Message Type :8 (Datagram) Expiry :-1 Feedback :0 (None) MQEncoding :0x '222' CCSID :0 Format : ' ' Priority :-1 Persistence :2 (As Q Definition) Message Id :000000000000000000000000000000000000000000000000 '........................' Correl. Id :000000000000000000000000000000000000000000000000 '........................' ReplyToQ : '................................................' ReplyToQMgr : '................................................' UserId : '............' MQMD after MQGET Message Descriptor (MQMD) Version :1 Report :00000000 Message Type :8 (Datagram) Expiry :-1 Feedback :0 (None) MQEncoding :0x '311' CCSID :500 Format : 'MQSTR ' Priority :0 Persistence :0 (Not Persistent) Message Id :C3E2D840D4D8F2F34040404040404040CA9296E793272132 '...@....@@@@@@@@.....'!2 ' Correl. Id :000000000000000000000000000000000000000000000000 '........................' ReplyToQ : ' ' ReplyToQMgr : 'MQ23 ' UserId : 'HUGHSON '
Hope this helps
Re: MQ - Error 2116 during an MQ get on Host Environment2012-12-05T15:50:12ZThis is the accepted answer. This is the accepted answer.
- SystemAdmin 110000D4XK
Thank you for your help.
I try to follow your suggestion even if I already tried to make some tests.
I inserted on my cobol program some display instructions in order to check how the MQMD is filled.
The result is below.
These values are referred to the test using MQGMO_CONVERT.
For some fields is shown the hexadecimal representation in order to better understand the value.
Meanwhile you examine this data, I make another test without using MQGMO_CONVERT and I let you know.
REPLYTQM 02T OPRCT
Re: MQ - Error 2116 during an MQ get on Host Environment2012-12-06T15:15:32ZThis is the accepted answer. This is the accepted answer.
- SystemAdmin 110000D4XK
One point, I would like to double check with you that this value you have printed out is decimal and not hex?
Re: MQ - Error 2116 during an MQ get on Host Environment2012-12-12T08:47:54ZThis is the accepted answer. This is the accepted answer.
- SystemAdmin 110000D4XK
I have not been able to get the test without MQGMO_CONVERT yet.
But to answer to your question I can say the value is decimal.
I think it is represented in this way because the data I wrote are obtained by using a display on a cobol program that invokes a call to a routine that directly use MQ instructions.
So the values are been obtained by displaying the communication area between the program and the MQ routine.
However I checked directly on the routine the value of encoding and is 311.
So I think the value we have to consider is the hexadecimal 311.
I let you know as soon as I have completed the other test.