cancel
Showing results for 
Search instead for 
Did you mean: 

Message Mapping Question

Former Member
0 Kudos

Is it possible to send the entire payload into a node on the target where this node is a string which can hold the payload? If so please let me know how to do it.

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

My recommendation would be then to handle this a completely different way. Take your receiver DT and the node you want to map to and set the type from xsd:string to click on Search help and pick the sender DT your getting the data from, then in mapping, map all the values straight over to the same fields in that node. It would be in the same format as if you tried to do it with a string, so it shouldn't cause problems.

This is only if you can modify the receiver DT though.

Former Member
0 Kudos

Is this payload going to consist of XML?

what is your receiver?

Former Member
0 Kudos

Paul,

Yes the source and target payloads are XMLs. Planing to use webservice as a receiver.

Former Member
0 Kudos

Hey

could you please clear one thing for us .

do u want the whole XML payload in ur single receiver tag? or u want all the values in the receiver tag.

suppose sender is

<Recordset>

<Tag1>Emp</Tag1>

<Tag2>Eid</Tag2>

<Recordset>

now on receiver side do u want the XML to be

<Recordset>

<MainTag><Tag1>Emp</Tag1><Tag2>Eid</Tag2></MainTag>

<Recordset>

like the above?

or you want

the receiver XML to be like

<Recordset>

<maintag>EmpEid</mainTag>

or like this one?

please let us know this so that we are able to help you more

Thanx

Aamir suhail

justin_santhanam
Active Contributor
0 Kudos

Jagathi,

Refer the two threads, I hope it will solve ur problem.

Best regards,

raj.

Former Member
0 Kudos

Aamir,

Thank you very much for your quick responses. This is what I want

SourceMessage:

<Recordset>

<Tag1>Emp</Tag1>

<Tag2>Eid</Tag2>

<Recordset>

TargetMessage:

<Target>

<SourceXML>

<Recordset><MainTag><Tag1>Emp</Tag1><Tag2>Eid</Tag2></MainTag></Recordset>

</SourceXML>

</Target>

Former Member
0 Kudos

hey

u can take help from this blog

/people/michal.krawczyk2/blog/2005/11/01/xi-xml-node-into-a-string-with-graphical-mapping

i would also suggest you to have a look at Raj's thread,specially the second one ,they have some very good ideas.

Thanx

Aamir

Former Member
0 Kudos

Thank you all for the helpful answers. Looks like this cannot be accomplished with Message Mapping, But need a Java or XSL. I will close this thread and award points.

Former Member
0 Kudos

I don't think so with standard functions.

but other way is possible.

you can parse a large string into multiple traget fields using "substring" function.

Former Member
0 Kudos

What is your source interface?

You can probably concatinate all the nodes of the souce together into the one entry, and if there are many record sets use a UDF as Queue.

Former Member
0 Kudos

I am planning to reuse this map between more than 1 message interface. They will all be XML messages and I won't know what are the tag names to concatenate. I basically want the full payload, don't want to concatenate.

Former Member
0 Kudos

Hey

yes,its possible.you can simple concatenate all the sender fields and send that to one receiver field

use the standard concat function if u dont have too many sender fields,but if u have lots of them,then use a UDF that will make the mapping more clear and readable

Thanx

Aamir suhail

justin_santhanam
Active Contributor
0 Kudos

Aamir & Paul,

He wants to send the entire payload , not the contents alone. I won't think so Concat function will help. Aamir, please correct me if i'm wrong.

Best regards,

raj.

Former Member
0 Kudos

Hey

yes Raj,you are correct,infact now i m a bit confused as to what kinda structure poster wants:)

lets see what poster says and then we can help him more

Thanx

Aamir

Message was edited by:

Aamir Suhail