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.
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.
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 ;
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