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 » General IBM MQ Support » EBCDIC to ACSII Conversion

Post new topic  Reply to topic
 EBCDIC to ACSII Conversion « View previous topic :: View next topic » 
Author Message
ramesh.govindaswamy
PostPosted: Wed Nov 01, 2006 11:25 pm    Post subject: EBCDIC to ACSII Conversion Reply with quote

Apprentice

Joined: 25 Oct 2005
Posts: 42

Hi,
I am facing some problem while converting the message from EBCDIC to ASCII format.My queue manager CCSID is 819. I am sending the message to the queue manager with ASCII format with the message level characterset as 819.while getting the reply ,the host application will send the response message in the format of EBCDIC and the characterset for the message is 37.
I have specified the MQC.GMO_CONVERT in my get message options, but still I can't able to convert the message into ASCII while getting the message from the queue.I am doing the readString and the writeSting method for reading the writing the message on the queue respectively.

Could you please any one suggest me where I am doing the mistake and do I need to change anything in the ccsid.tbl for the conversion.

Please help me on this.

With regards
Ramesh.G
Back to top
View user's profile Send private message Send e-mail
Mr Butcher
PostPosted: Thu Nov 02, 2006 12:56 am    Post subject: Reply with quote

Padawan

Joined: 23 May 2005
Posts: 1716

what is the format of the message (the mqmd format in the message header)? Mq will only convert if the format is set properly.
_________________
Regards, Butcher
Back to top
View user's profile Send private message
Vitor
PostPosted: Thu Nov 02, 2006 1:04 am    Post subject: Re: EBCDIC to ACSII Conversion Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

ramesh.govindaswamy wrote:
Hi,
do I need to change anything in the ccsid.tbl for the conversion.



I'd doubt it. IIRC that's one of the standard conversions.

It's quite rare in my expereince to need to fiddle with ccsid.tbl. And not something to be attempted lightly.

I'd investigate the message format as previously suggested first.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
ramesh.govindaswamy
PostPosted: Thu Nov 02, 2006 1:15 am    Post subject: Reply with quote

Apprentice

Joined: 25 Oct 2005
Posts: 42

Hi,
I have set the message format type as string.
MQMessage lvMQMessage = new MQMessage();
lvMQMessage.format = MQC.MQFMT_STRING

I have not set any Encoding in the message.Please suggest me.
Back to top
View user's profile Send private message Send e-mail
Vitor
PostPosted: Thu Nov 02, 2006 1:31 am    Post subject: Re: EBCDIC to ACSII Conversion Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

ramesh.govindaswamy wrote:
.My queue manager CCSID is 819. I am sending the message to the queue manager with ASCII format with the message level characterset as 819.while getting the reply ,the host application will send the response message in the format of EBCDIC and the characterset for the message is 37.


So EBCDIC application is doing a get with convert & this works properly because it's able to interpret the message? It then generates a reply, sends it back to ASCII application which does a get with convert that fails? And you're certain that because you've sent the request message with a Format of MQFMT_STRING the other application honours that & the reply message has the same Format? With the CCSID set to match the EBCDIC contents?

If that's all correct & you're certain, are both applications on their own queue manager or is one cliented onto the other?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu Nov 02, 2006 3:53 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

ramesh.govindaswamy wrote:
Hi,
I have set the message format type as string.
MQMessage lvMQMessage = new MQMessage();
lvMQMessage.format = MQC.MQFMT_STRING

I have not set any Encoding in the message.Please suggest me.

I have seen strange things happening on a JMS Client if the MQ_ENCODING is not set right on the message. Either set it to 0 (should default to the qmgr) or set it to the right value for the platform, or use one of the valid "literal" values. Just because it will accept any integer does not mean that the content will not cause a problem further down the road.

Even stranger things: If the encoding is not set right, using a JMS client on a machine with the MQ client only gives you an exception stating the encoding is not right...; using JMS Client on a machine with the MQ Server & client installed will give you the message ??? (V6.0.1.0) and the message was a javax.jms.TextMessage....

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
ramesh.govindaswamy
PostPosted: Thu Nov 02, 2006 4:06 am    Post subject: Reply with quote

Apprentice

Joined: 25 Oct 2005
Posts: 42

Hi,
I did a small change in my QueueManager CCSID.I changed the CCSID from 819 to 1208.While connecting the QueueManager I am setting the MQEnvironment.CCSID as 1208 and while sending and receving the message I am setting the message level characterSetId as 1208.

The host application is able to read the message from the queue, while sending the response message(EBCDIC format) they are setting the message level characterSetId as 37.

In both the side the message format and the encoding are MQC.MQFMT_STRING, MQC.MQENC_NATIVE respectively.

While reading the response message I am getting "java.io.EOFException".I am using the MQ version of 5.3 with the CSD level of 01.I have specified the MQC.MQGMO_CONVERT option in the get message option.

Please let me know how can I over come the EOF exception.
Back to top
View user's profile Send private message Send e-mail
fjb_saper
PostPosted: Thu Nov 02, 2006 4:12 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

5.3 CSD 01 ?? Get the latest CSD ASAP. You should be @ CSD 12 or above...
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
ramesh.govindaswamy
PostPosted: Thu Nov 02, 2006 4:21 am    Post subject: Reply with quote

Apprentice

Joined: 25 Oct 2005
Posts: 42

Saper,
Could you please check whether the way I am approaching(Conversion from EBCDIC to ASCII) correct or not.In the mean time I will update my CSD level.
Back to top
View user's profile Send private message Send e-mail
Vitor
PostPosted: Thu Nov 02, 2006 4:29 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

ramesh.govindaswamy wrote:


While reading the response message I am getting "java.io.EOFException".I am using the MQ version of 5.3 with the CSD level of 01....Please let me know how can I over come the EOF exception.


Upgrade the CSD level!

Levels below 5.3.10 are notoriously flaky in their Java support. I'd upgrade and retry before you look at your code again (which does appear correct at face value)
_________________
Honesty is the best policy.
Insanity is the best defence.
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 » General IBM MQ Support » EBCDIC to ACSII Conversion
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.