ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Character Code Set Error while sending MQ message to IMS

Post new topic  Reply to topic
 Character Code Set Error while sending MQ message to IMS « View previous topic :: View next topic » 
Author Message
amitkan2000
PostPosted: Thu May 26, 2011 4:52 am    Post subject: Character Code Set Error while sending MQ message to IMS Reply with quote

Novice

Joined: 22 Feb 2010
Posts: 12

Hi,

We are facing problem when sending MQ Message from WMB to IMS with the character code set and encoding.

We are doing following configuration before sending the message to IMS -
Code:

            SET OutputRoot.MQMD."Encoding"                 = 785;
            SET OutputRoot.MQMD.CodedCharSetId        = 500;
            SET OutputRoot.MQMD.Format                      = 'MQIMS   ';
            SET OutputRoot.Properties.CodedCharSetId   = 500;
            SET OutputRoot.MQIIH.Encoding                   =  785;
            SET OutputRoot.MQIIH.CodedCharSetId             =  500;


At the IMS end
Quote:
cent character (EBCDIC 4a) is getting converted into HAT ^ (EBCDIC b0)


What I tried to replace the X'bo by X'4a inside esql using REPLACE function after converting the CHARACTER in BLOB, but while converting back BLOB to CHARACTER after replace, it is giving me runtime exception "Unconvertable Character".

Code:

                  DECLARE tempStr BLOB ;
                  DECLARE blobHatSymb BLOB X'b0';
                  DECLARE blobCentSymb BLOB X'4a';
                 
                 
                  SET tempStr = CAST (strInputStream AS BLOB CCSID OutputRoot.Properties.CodedCharSetId);
                 
                  SET tempStr = REPLACE (tempStr, blobHatSymb,blobCentSymb);
                  SET strInputStream = CAST(tempStr AS CHAR CCSID InputRoot.Properties.CodedCharSetId Encoding InputRoot.Properties.Encoding);


Has somebody faces the same problem and solve that, pl give some pointers.

Thanks in advance.

Amit
Back to top
View user's profile Send private message
amitkan2000
PostPosted: Thu May 26, 2011 4:56 am    Post subject: Reply with quote

Novice

Joined: 22 Feb 2010
Posts: 12

Here is the difference of string at the IMS end.
Quote:
WAXRECP-WBI : TRANS01 0000REQRECP VER0002 EN-US 4UZJ6BP20T2111111 EOF -- BAD

WAXRECP-WBI : TRANS01 0000REQRECP¢VER0001¢EN-US¢1FUYNMDB8VP797127¢EOF -- Correct


You can see in the correct string cent sign is available but in the bad string it is absent. The space in the BAD string is the x'b0 character while it should be x'4a
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu May 26, 2011 5:13 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

What encoding ( code page ) is IMS using to decode the bytes into characters?
Back to top
View user's profile Send private message
amitkan2000
PostPosted: Thu May 26, 2011 5:22 am    Post subject: Reply with quote

Novice

Joined: 22 Feb 2010
Posts: 12

EBCDIC 500
Back to top
View user's profile Send private message
rekarm01
PostPosted: Thu May 26, 2011 10:55 pm    Post subject: Re: Character Code Set Error while sending MQ message to IMS Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

amitkan2000 wrote:
Code:
SET OutputRoot. ...

What does InputRoot look like? A proper conversion depends on both a correct input ccsid and correct output ccsid.

amitkan2000 wrote:
At the IMS end
Quote:
cent character (EBCDIC 4a) is getting converted into HAT ^ (EBCDIC b0)

For ccsid=500, the "cent" character is supposed to be X'B0'. The "HAT" character is X'5F', and the left bracket is X'4A'.

Maybe ccsid=500 is the wrong output ccsid. It seems like the IMS app might prefer ccsid=37.

amitkan2000 wrote:
What I tried to replace the X'b0 by X'4a inside esql using REPLACE function ...

That's a bad idea. The problem with that approach is that it's difficult to derive a complete set of characters that need "fixing". If some get fixed, but others don't, the end result is a message that won't fit any ccsid. For example, here's a complete list of "problem characters" between EBCDIC ccsids 37 and 500:
Code:
Character  IBM-037   IBM-500
    |       X'4F'     X'BB'
    ¢       X'4A'     X'B0'
    !       X'5A'     X'4F'
    ¬       X'5F'     X'BA'
    ^       X'B0'     X'5F'
    [       X'BA'     X'4A'
    ]       X'BB'     X'5A'

For other EBCDIC ccsids, the list of problem characters may be different.

There are additional errors in the posted code that are causing the "Unconvertable Character" exception, but it's better to throw the code away, than to try to find and fix the errors.

Make sure that the input ccsid correctly describes the input message, and that the output ccsid matches what the receiving apps actually expects.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Character Code Set Error while sending MQ message to IMS
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.