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 » Namespace question

Post new topic  Reply to topic
 Namespace question « View previous topic :: View next topic » 
Author Message
sweety176
PostPosted: Wed Sep 07, 2005 9:44 am    Post subject: Namespace question Reply with quote

Apprentice

Joined: 24 Aug 2005
Posts: 30

Hi all
My input XML begins as
Code:
<?xml version = "1.0" encoding = "UTF-8"?>
<SOAP-Env:Envelope  xmlns:hrq="http://xmlcoe.jpmorganchase.com/header/v1_3" xmlns:dqrq="http://xmlcoe.jpmorganchase.com/CHF/DocumentQueryRequest" xmlns:jpmc="http://xmlcoe.jpmorganchase.com/mismo/extensions" xmlns:SOAP-Env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/
http://xmlcoe.jpmorganchase.com:8000/CHF/DocumentQry/Schemas/DocumentQryRqSOAP.xsd">
<!--xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ DocumentQryRqSOAP.xsd">-->
   <SOAP-Env:Body>
      <dqrq:DocumentQryRqMsg>
         <hrq:HdrOrigRqRmmMsgGrp>

and output XML as
Code:
<?xml version="1.0" encoding="UTF-8"?>
<SOAP-Env:Envelope xmlns:hrq="http://xmlcoe.jpmorganchase.com/header/v1_3" xmlns:jpmc="http://xmlcoe.jpmorganchase.com/mismo/extensions" xmlns:SOAP-Env="http://schemas.xmlsoap.org/soap/envelope/" xmlns:dqrqfn="http://xmlcoe.jpmorganchase.com/CHF/DocumentQueryRequest/FN" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ http://xmlcoe.jpmorganchase.com:8000/CHF/DocumentQry/Schemas/DocumentQryRqFNSOAP.xsd">
<!--xsi:schemaLocation="http://schemas.xmlsoap.org/soap/envelope/ DocumentQryRqFNSOAP.xsd">-->
   <SOAP-Env:Body>
      <dqrqfn:DocumentQryRqMsg>
         <hrq:HdrOrigRqRmmMsgGrp>

to generate the output XML i mapped the attributes in the following manner
Code:
DECLARE C INTEGER;
SET C = CARDINALITY(InputRoot.*[]);
DECLARE I INTEGER;
SET I = 1;
WHILE I < C DO
   SET OutputRoot.*[I] = InputRoot.*[I];
   SET I=I+1;
END WHILE;
-- Enter SQL below this line.  SQL above this line might be regenerated, causing any modifications to be lost.
/************************************************************************************************************
Purpose: Transforms FN Response XML to HELOS Response XML
************************************************************************************************************/

CREATE FIELD OutputRoot.XML."SOAP-Env:Envelope";
SET OutputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:dqrqfn" = InputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:dqrq";
SET OutputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:hrq" = InputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:hrq";
SET OutputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:SOAP-Env" = InputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:SOAP-Env";
SET OutputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:xsi" = InputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:xsi";
SET OutputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xsi:schemaLocation" = InputRoot.XML."SOAP-Env:Envelope".(XML.Attribute)"xmlns:schemaLocation";

--Map Output Headers to Input Headers
CREATE FIELD OutputRoot.XML."SOAP-Env:Envelope"."SOAP-Env:Body"."dqrqfn:DocumentQryRsMsg"."HdrRsRmmMsgGrp" FROM InputRoot.XML."SOAP-Env:Envelope"."SOAP-Env:Body"."dqrq:DocumentQryRsMsg"."HdrRsRmmMsgGrp";

But it doesnt work.
I think the problem is when i map dqrqfn: to dqrq which i shouldnt
Could somebody please tell me how to create that particular namespace in output and map the rest from input
Thanks in Advance
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Sep 07, 2005 9:58 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I think the problem is either that you are trying to use 2.1 with namespaces - which is poorly supported at best, or you are using the XML domain when you should obviously be using XMLNS (XML with NameSpaces).
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
sweety176
PostPosted: Wed Sep 07, 2005 10:28 am    Post subject: worked before Reply with quote

Apprentice

Joined: 24 Aug 2005
Posts: 30

Hi
When its the same namespace both in input and output I am able to generate it without using XMLNS
But now since its dqrqfn on one side and dqrq on other it doesnt seem working.
Could you please tell me how to create that namespace in output? Regards
Sweety
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Sep 07, 2005 10:32 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I already told you how to create the namespace in the output.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
sweety176
PostPosted: Wed Sep 07, 2005 11:44 am    Post subject: Reply with quote

Apprentice

Joined: 24 Aug 2005
Posts: 30

HI
I wrote the code as below
Code:

DECLARE Pointer REFERENCE TO OutputRoot.XML."SOAP-Env:Envelope";
CREATE FIRSTCHILD of Pointer TYPE 0x07000012 NAMESPACE 'xmlns' NAME 'dqrqfn' VALUE 'http://xmlcoe.jpmorganchase.com/CHF/DocumentQueryRequest';

Is it correct.
Regards
Sweety
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Sep 07, 2005 12:19 pm    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

sweety176 wrote:
Is it correct.

Does it work?

Does it throw an error?

Does it match the syntax as explained in the documentation?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
sweety176
PostPosted: Wed Sep 07, 2005 12:26 pm    Post subject: Reply with quote

Apprentice

Joined: 24 Aug 2005
Posts: 30

There is a peculiar problem here that it takes hrs for the message to get from i/p to o/p queue so I m not sure if it works yet.
The documentation I found was very confusing but this is what i could infer from it.
It would be very helpful for me if you could provide me the links describing such transformations. I tried using MQSI Help but didnt help much.
Reagrds
Sweety
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 » Namespace question
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.