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 » Doubt Regarding the special character conversion

Post new topic  Reply to topic
 Doubt Regarding the special character conversion « View previous topic :: View next topic » 
Author Message
namakkal
PostPosted: Sun May 31, 2009 5:51 am    Post subject: Doubt Regarding the special character conversion Reply with quote

Novice

Joined: 06 Feb 2009
Posts: 19

Hi,

i have a doubt converting special char symbol into character by using BITSTREAM.

i am getting the unconvertable character error while try to convert special character to character( example. ® ...)

can any one please tell to how to solve this problem .

My code is like this

DECLARE bBitInputMsg BLOB ASBITSTREAM(OutputRoot.XMLNSC CCSID InputRoot.Properties.CodedCharSetId ENCODING InputRoot.Properties.Encoding);


DECLARE cCharInputMsg CHAR CAST (bBitInputMsg AS CHAR CCSID InputRoot.Properties.CodedCharSetId ENCODING InputRoot.Properties.Encoding);


First i am conveting the XML into BLOB then i am converting the BLOB to Character that time i am getting the Convertion error if the input messaeg have some special character. please help me on this .

Regards
Sathish
Back to top
View user's profile Send private message Send e-mail
kimbert
PostPosted: Sun May 31, 2009 12:48 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

What's the overall goal that you're trying to accomplish?
Back to top
View user's profile Send private message
rekarm01
PostPosted: Sun May 31, 2009 3:21 pm    Post subject: Re: Doubt Regarding the special character conversion Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

namakkal wrote:
Code:
DECLARE bBitInputMsg BLOB ASBITSTREAM(OutputRoot.XMLNSC CCSID InputRoot.Properties.CodedCharSetId ENCODING InputRoot.Properties.Encoding);

'OutputRoot' should probably be 'InputRoot'. 'ENCODING' is harmless, but unnecessary for XMLNSC.

namakkal wrote:
i am getting the unconvertable character error while try to convert special character to character( example. ® ...)

Which error? Which code is generating the error? Be specific.

Which character encoding does the input header ccsid specify?
Which character encoding does the input body actually use?
Are these different?

kimbert wrote:
What's the overall goal that you're trying to accomplish?
Back to top
View user's profile Send private message
broker_new
PostPosted: Sun May 31, 2009 6:29 pm    Post subject: Reply with quote

Yatiri

Joined: 30 Nov 2006
Posts: 614
Location: Washington DC

I guess "namakkal" is trying to convert the input message to a string.
_________________
IBM ->Let's build a smarter planet
Back to top
View user's profile Send private message
namakkal
PostPosted: Sun May 31, 2009 8:45 pm    Post subject: Re: Doubt Regarding the special character conversion Reply with quote

Novice

Joined: 06 Feb 2009
Posts: 19

rekarm01 wrote:
namakkal wrote:
Code:
DECLARE bBitInputMsg BLOB ASBITSTREAM(OutputRoot.XMLNSC CCSID InputRoot.Properties.CodedCharSetId ENCODING InputRoot.Properties.Encoding);

'OutputRoot' should probably be 'InputRoot'. 'ENCODING' is harmless, but unnecessary for XMLNSC.

namakkal wrote:
i am getting the unconvertable character error while try to convert special character to character( example. ® ...)

Which error? Which code is generating the error? Be specific.

Which character encoding does the input header ccsid specify?
Which character encoding does the input body actually use?
Are these different?

kimbert wrote:
What's the overall goal that you're trying to accomplish?


Hi ,
i am trying to convert the XMLNSC message into string but some arrtibutes having special character like (®). i could not able to convert the special char into character.
Regards
Sats
Back to top
View user's profile Send private message Send e-mail
kimbert
PostPosted: Mon Jun 01, 2009 12:50 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
i am trying to convert the XMLNSC message into string
I guessed that...but why do you want to do this? There may be a better way to meet the requirement.
Back to top
View user's profile Send private message
ein
PostPosted: Tue Jun 09, 2009 9:32 pm    Post subject: Reply with quote

Centurion

Joined: 14 Mar 2009
Posts: 108

kimbert wrote:
Quote:
i am trying to convert the XMLNSC message into string
I guessed that...but why do you want to do this? There may be a better way to meet the requirement.


Hello Kimbert,

What is the better way,
How we can archive this?
Back to top
View user's profile Send private message
Vitor
PostPosted: Tue Jun 09, 2009 11:53 pm    Post subject: Reply with quote

Grand High Poobah

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

ein wrote:
What is the better way,


Answer the question and maybe we'll come up with something.

ein wrote:
How we can archive this?


Archive or Achieve?

If you're simply trying to archive a message, why convert it to a string?

If you're trying to achieve a goal to which converting XML to a string is a means to an end (and have the same issues with spelling that I do!) the question remains - why convert XML to a string like this? What is the requirement? What is the goal?

There may be a better way to achieve "the goal" than converting XML to string.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
ein
PostPosted: Wed Jun 10, 2009 3:25 am    Post subject: Reply with quote

Centurion

Joined: 14 Mar 2009
Posts: 108

Thanks for rply

I cud have tried with ASBITSTREAM ... what namakkal has mentioned. it was failed.

And Even I have my own solution i.e to send the actual message in environment variables.
I cud have archived the requirement. But I am looking for better solution than me.

You said that you have better solution. that way i have asked you.

Here is my requirement.

WTX is sending Data with special characters in XML format. WMB has to identify the some of the fields and send it to WPG in RFH2 header and read the actuall content which i have tried to read as string has some special characters.

Now you understood the requirement.

Now tell me what is your solution, if you know.
Back to top
View user's profile Send private message
kimbert
PostPosted: Wed Jun 10, 2009 4:04 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
You said that you have better solution. that way i have asked you.
I don't think anybody said that. We suggested that there *might* be a better solution.

Quote:
Here is my requirement.

WTX is sending Data with special characters in XML format. WMB has to identify the some of the fields and send it to WPG in RFH2 header and read the actuall content which i have tried to read as string has some special characters.

Now you understood the requirement.
Sorry - I don't understand that. What is WPG? Why does WMB have to identify some of the fields? Who has to read this 'actual content' and why?
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Jun 10, 2009 4:08 am    Post subject: Reply with quote

Grand High Poobah

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

ein wrote:
Now you understood the requirement.


And thank you for the detailed explaination.

ein wrote:
Now tell me what is your solution, if you know.


Well I'll ask another question if I may - does the CCSID of the RFH2 support the special characters? If not, what drove that decision?
_________________
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 » WebSphere Message Broker (ACE) Support » Doubt Regarding the special character 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.