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 » mrm charset conversion

Post new topic  Reply to topic
 mrm charset conversion « View previous topic :: View next topic » 
Author Message
deceiver
PostPosted: Fri Jun 04, 2004 3:27 am    Post subject: mrm charset conversion Reply with quote

Newbie

Joined: 04 Jun 2004
Posts: 4

newbie question: how do i cast one charset to another using esql?

i have tried this but i know the syntax is off

CALL CopyEntireMessage();

DECLARE I INTEGER 2;
DECLARE J INTEGER CARDINALITY(InputRoot.MRM.Record[]);

WHILE I <= J DO

SET OutputRoot.MRM.Record[I-1] = CAST(InputRoot.MRM.Record[I] AS CCSID 819);

SET I = I + 1;

END WHILE;
Back to top
View user's profile Send private message
fazz
PostPosted: Fri Jun 04, 2004 4:07 am    Post subject: Reply with quote

Centurion

Joined: 20 Feb 2004
Posts: 144
Location: England

You could set the MQMD elements...

SET OutputRoot.MQMD.Encoding = ?;
SET OutputRoot.MQMD.CodedCharSetId = ?;

..and let MQ handle the conversion from one code page set to another.
Back to top
View user's profile Send private message
deceiver
PostPosted: Fri Jun 04, 2004 8:53 am    Post subject: but what if Reply with quote

Newbie

Joined: 04 Jun 2004
Posts: 4

I still want to do all my conversion in using CAST. Is my code totally wrong or..?


Being a newbie i tried setting the MQMD properties but that only changes headers and not the payload. I put a trace right after the compute node and nothing in the payload has changed. By the way Where/How in MQ do you set the conversion you suggest? Is it in some properties somewhere?

easy-to-follow-answer answer please =)
Back to top
View user's profile Send private message
EddieA
PostPosted: Fri Jun 04, 2004 9:58 am    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

Quote:
I still want to do all my conversion in using CAST

Why?
Quote:
I put a trace right after the compute node and nothing in the payload has changed

That's because inside WMQI everything is held as unicode (well, except BLOBs), and is only converted to the correct CCSID when the message is converted to wire format. Which is, usually, when it is written to the output queue. Of BLOBed

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
deceiver
PostPosted: Fri Jun 04, 2004 10:26 am    Post subject: Reply with quote

Newbie

Joined: 04 Jun 2004
Posts: 4

ok. I give up =) No more cast for me. I just wanted to know cause I want to learn.

To sum everything up. The best for me is to

1. set the convert option in MQinput to ccsid 819
2. set the MQMD properties as specified in the reply above

That will take care of everything.

Just curious, why do i need to set the MQMD? Isnt it enough just to use the conversion option in MQinput?
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 » mrm charset 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.