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 » Special character

Post new topic  Reply to topic
 Special character « View previous topic :: View next topic » 
Author Message
SKK
PostPosted: Tue Dec 13, 2005 8:32 am    Post subject: Special character Reply with quote

Acolyte

Joined: 09 May 2005
Posts: 67

Hi.

I'm trying to populate MQRFH2 NameValueData with special character "&".

For Ex:
set OutputRoot.XML.Result[I].ID='Test&Test';
set OutputRoot.MQRFH2.NameValueData[] = OutputRoot.XML.Result[];

I get NameValueData populated as <ID>Test&amp;Test</ID>.

Can anyone let me know, how to avoid amp; in the above.


Regards
SKK
_________________
Regards,
SKK
Back to top
View user's profile Send private message
JT
PostPosted: Tue Dec 13, 2005 8:52 am    Post subject: Reply with quote

Padawan

Joined: 27 Mar 2003
Posts: 1564
Location: Hartford, CT.

Do a search for 'CDATA'
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Dec 13, 2005 8:58 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

JT wrote:
Do a search for 'CDATA'


I didn't think that the RFH2 was properly XML...
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
SKK
PostPosted: Tue Dec 13, 2005 10:50 am    Post subject: Special Character Reply with quote

Acolyte

Joined: 09 May 2005
Posts: 67

Hi,

I tried using,

set OutputRoot.XML.Result[I].ID.(XML.CDataSection)='Test&Test';
set OutputRoot.MQRFH2.NameValueData[] = OutputRoot.XML.Result[];

still I get

NameValueData populated as <ID>Test&amp;Test</ID>.


Regards
suresh.
_________________
Regards,
SKK
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Tue Dec 13, 2005 10:54 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Where are you actually seeing the &amp; ? In a trace in the flow, or outside the flow?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
SKK
PostPosted: Tue Dec 13, 2005 11:34 am    Post subject: Reply with quote

Acolyte

Joined: 09 May 2005
Posts: 67

Hi

I see it outside the message flow, i'm using RFHUtil to view the message.

Regards
SKK
_________________
Regards,
SKK
Back to top
View user's profile Send private message
SKK
PostPosted: Tue Dec 13, 2005 1:52 pm    Post subject: Reply with quote

Acolyte

Joined: 09 May 2005
Posts: 67

Hi,

Here is the trace, in this field is getting populated properly.

(
(0x1000000)Properties = (
(0x3000000)MessageSet = ''
(0x3000000)MessageType = ''
(0x3000000)MessageFormat = ''
(0x3000000)Encoding = 273
(0x3000000)CodedCharSetId = 819
(0x3000000)Transactional = TRUE
(0x3000000)Persistence = FALSE
(0x3000000)CreationTime = GMTTIMESTAMP '2005-12-13 19:28:09.820'
(0x3000000)ExpirationTime = -1
(0x3000000)Priority = 0
(0x3000000)ReplyIdentifier = X'000000000000000000000000000000000000000000000000'
(0x3000000)ReplyProtocol = 'MQ'
(0x3000000)Topic = NULL
)
(0x1000000)MQMD = (
(0x3000000)SourceQueue = 'XML.Inbound.Q'
(0x3000000)Transactional = TRUE
(0x3000000)Encoding = 273
(0x3000000)CodedCharSetId = 819
(0x3000000)Format = 'MQHRF2'
(0x3000000)Version = 2
(0x3000000)Report = 0
(0x3000000)MsgType = 8
(0x3000000)Expiry = -1
(0x3000000)Feedback = 0
(0x3000000)Priority = 0
(0x3000000)Persistence = 0
(0x3000000)MsgId = X'414d5120514d554e4254523030322020439bbb6820016a04'
(0x3000000)CorrelId = X'000000000000000000000000000000000000000000000000'
(0x3000000)BackoutCount = 0
(0x3000000)ReplyToQ = ' '
(0x3000000)ReplyToQMgr = 'QMUNBTR002 '
(0x3000000)UserIdentifier = 'mqm '
(0x3000000)AccountingToken = X'0332313000000000000000000000000000000000000000000000000000000006'
(0x3000000)ApplIdentityData = ' '
(0x3000000)PutApplType = 28
(0x3000000)PutApplName = ' '
(0x3000000)PutDate = DATE '2005-12-13'
(0x3000000)PutTime = GMTTIME '19:28:09.820'
(0x3000000)ApplOriginData = ' '
(0x3000000)GroupId = X'000000000000000000000000000000000000000000000000'
(0x3000000)MsgSeqNumber = 1
(0x3000000)Offset = 0
(0x3000000)MsgFlags = 0
(0x3000000)OriginalLength = -1
)
(0x1000000)MQRFH2 = (
(0x3000000)Version = 2
(0x3000000)Format = 'MQSTR '
(0x1000000)NameValueData = (
(0x1000000)SENDER_ID = (
(0x2000000) = 'TEST&TEST'
)
(0x1000000)RECEIVER_ID = (
(0x2000000) = 'TEST'
)
(0x1000000)QUEUE_NAME = (
(0x2000000) = 'TEST'
)
(0x1000000)QUEUE_MANAGER = (
(0x2000000) = 'QMUNBTR002'
)
(0x1000000)TYPE = (
(0x2000000) = 'NULL'
)
(0x1000000)DESTINATION_TYPE = (
(0x2000000) = 'NULL'
)
(0x1000000)REGION = (
(0x2000000) = 'NULL'
)
)
(0x1000000)usr = (
(0x1000000)SenderId = (
(0x2000000) = 'TEST&TEST'
)
(0x1000000)SenderQual = (
(0x2000000) = '08'
)
(0x1000000)ReceiverId = (
(0x2000000) = 'TEST'
)
(0x1000000)ReceiverQual = (
(0x2000000) = '08'
)
)
(0x1000000)mcd = (
(0x1000000)Msd = (
(0x2000000) = 'none'
)
)
)
(0x1000000)BLOB = (
(0x3000000)BLOB = X'4953412a30302a202020202020202020202a30302a202020202020202020202a30382a5445535426544553542020202020202
a30382a5445535420202020202020202020202a3035303332312a313330342a552a30303430312a3030303030353731362a302a502a3c7e47532a46412a39
3236373237363030302a393235323231313130302a32303035303332312a313330342a333738322a542a3030343031305543537e53542a3939372a3030303
030333835307e414b312a47502a313830307e414b322a3838302a31383030303030317e414b352a417e414b392a412a312a312a317e53452a362a30303030
30333835307e47452a312a333738327e4945412a312a3030303030353731367e'
)
)


Regards
SKK.
_________________
Regards,
SKK
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Tue Dec 13, 2005 8:59 pm    Post subject: Reply with quote

Grand High Poobah

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

&amp; is the normal xml notation for the & character in xml format.
So do not worry about it. If you retrieve the information you should see
Test & Test and be fine.

Enjoy
Back to top
View user's profile Send private message Send e-mail
EddieA
PostPosted: Tue Dec 13, 2005 10:52 pm    Post subject: Reply with quote

Jedi

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

Quote:
&amp; is the normal xml notation for the & character in xml format.

Yes, except that the Name/Value pairs in the RFH2 are not "true" XML. It will depend on how you are reading them.

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
jefflowrey
PostPosted: Wed Dec 14, 2005 4:53 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I wonder if using XML.AsIsElementContent would work here?

I'm sure that copying from XML to Environment and then to RFH2 will work, as it will strip off the parser association that is causing the transformation.

But that's slower.
_________________
I am *not* the model of the modern major general.
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 » Special character
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.