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 » Problems with Namespace

Post new topic  Reply to topic
 Problems with Namespace « View previous topic :: View next topic » 
Author Message
wbimbuser
PostPosted: Tue Jan 25, 2005 10:11 am    Post subject: Problems with Namespace Reply with quote

Newbie

Joined: 08 Oct 2004
Posts: 4

Hi there,

I have a problem positioning in an XML-document.
we are using the following XML-File (excerpt):

Code:
<?xml version="1.0" encoding="ISO-8859-1"?>
<xyz:Meldung xmlns:xyz=... xmlns:abc=...>
 <abc:Header>
  <abc:Version abc:Type="SRC">
    <abc:Konn>01.10</abc:Konn>
    <abc:Appl>12.12.12.12</abc:Appl>
  </abc:Version>
  <abc:Version abc:Type="DST">
    <abc:Konn>01.00</abc:Konn>
    <abc:Appl>01.47.11.08</abc:Appl>
  </abc:Version>
 </abc:Header>
</xyz:Meldung>

I want to get the value of "Appl" in the second part "DST" and tried the following:

Code:
DECLARE strVersion CHARACTER;

DECLARE MainNS CHARACTER GetTargetNamespace(InputRoot.XMLNS);
DECLARE Main NAMESPACE MainNS ;
DECLARE SubNS CHARACTER FIELDVALUE(InputRoot.XMLNS.xyz:Meldung.(XML.NamespaceDecl)xmlns.abc);

DECLARE Sub NAMESPACE SubNS;
DECLARE appTree REFERENCE TO InputRoot.XMLNS.xyz:Meldung.abc:Header.abc:Version[2];

SET strVersion = FIELDVALUE(appTree.abc:ApplVersion.abc);


However, I can't seem to get my value, the statement DECLARE appTree always generates an Exception.

What am I doing wrong?

Thanks in advance.

regards,
Martin
Back to top
View user's profile Send private message
JT
PostPosted: Tue Jan 25, 2005 11:02 am    Post subject: Reply with quote

Padawan

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

Post the Exception.
Back to top
View user's profile Send private message
TonyD
PostPosted: Tue Jan 25, 2005 3:42 pm    Post subject: Reply with quote

Knight

Joined: 15 May 2001
Posts: 540
Location: New Zealand

Try:
Code:

(XML.NamespaceDecl)xmlns:abc

(colon instead of period).

Also am not sure what you want 'strVersion' to be
Code:

SET strVersion = FIELDVALUE(appTree.abc:ApplVersion.abc);

As the statement stands I don't think it would work...you have an 'Appl' and a 'Version' but no 'ApplVersion', and the final 'abc' needs to qualify something.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Problems with Namespace
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.