Author |
Message
|
Satyam_WMQI |
Posted: Sat Feb 04, 2006 3:16 am Post subject: Transforming XML to SWIFT |
|
|
Newbie
Joined: 04 Feb 2006 Posts: 3 Location: India
|
Hi
I'am trying to find the workaround for a problem :
My input message is in the XML format. One of the input tags contains the message that I need to transform to SWIFT and parse through the output message set and send the output in the XML format with the transformed SWIFT in one of the tags in this output XML.
Approach that I have followed is:
First Compute Node
1. Take the whole input message to an Environment variable.
2. Transform the Message within the XML tag to SWIFT using message set.
3.Output of the compute node will be in the MRM domain
ResetContentDescriptor
Reset the domain of the message from MRM to BLOB
Second Compute Node
1.Assign the Output message format as XML.
2.Assign the Environment Variable to the XML.
3.Cast the InputBody.BLOB.BLOB to character and assign to the output XML tag
This is working but I'am interested in handiling it all in the single compute node if possible.
The problem with this is after transformation I'am unable to access OutputRoot.MRM to assign it to the XML tag.
OutputRoot.MRM is returning NULL.
Please help.
Environment - WMQI
Thanks
Ups |
|
Back to top |
|
 |
jefflowrey |
Posted: Sat Feb 04, 2006 6:13 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Okay.
Remember that you need to use Create Field to assign a parser to elements in the Environment tree, if you need them to retain parser specific values. You can create an XML tree this way, and a separate tree that has your MRM parser.
So you could do all of your transformation work on structures in the Environment tree. Or you could choose which substructure was smaller (and thus faster to copy between nodes and faster to process) and use Body to hold and manipulate those.
Then you can either end your flow with an RCD that sets things to the final output, or you can just set the appropriate OutputRoot.Properties values. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
Satyam_WMQI |
Posted: Wed Feb 08, 2006 7:01 am Post subject: |
|
|
Newbie
Joined: 04 Feb 2006 Posts: 3 Location: India
|
Thanks for the response.
I tried the way you suggested but its not getting the value from the Root.
The code I'am using is :
CREATE FIELD Environment.Message;
CREATE LASTCHILD OF Environment.Message NAME 'OrgMESSAGE' VALUE InputRoot.XML;
When I try to assign the
Environment.Message.OrgMESSAGE to my OutputRoot, it gets NULL .
Code used :
CREATE LASTCHILD OF OutputRoot.XML VALUE Environment.Message.OrgMESSAGE ;
Also I tried giving a name as
CREATE LASTCHILD OF OutputRoot.XML Name 'MyMESSAGE' VALUE Environment.Message.OrgMESSAGE ;
Please advice. |
|
Back to top |
|
 |
jefflowrey |
Posted: Wed Feb 08, 2006 7:03 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You have to use the DOMAIN clause to assign the parser. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
Satyam_WMQI |
Posted: Thu Feb 09, 2006 1:47 am Post subject: |
|
|
Newbie
Joined: 04 Feb 2006 Posts: 3 Location: India
|
I tired the same.
But the OutputRoot.MRM is retuning NULL.
Is there some other way that I can access the whole message body in the MRM domain? |
|
Back to top |
|
 |
|