cancel
Showing results for 
Search instead for 
Did you mean: 

Creating new nodes dynamically in message mapping

Former Member
0 Kudos

Gurus,

Source Structure is

...

<Phone></Phone>

<Phone></Phone>

....

And I want to create target structure as for this Node1

.......

<Phones>

<Phone1>Has value from first Phone Node in source</Phone1>

<Phone2>Has value from second Phone Node in source</Phone2>

</Phones>

......

The requirement is that I want to create <Phone1><Phone2> .........<PhoneN> nodes dynamically based on the number of <Phone> nodes in Source Structure. The cardinality of <Phone> node in Source is 0 to Unbound.

Any suggestion ...?

Thanking you all in advance.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Use a javamapping or xsl mapping, because in the message mapping you have a defined xml structure.

Regards

Ivan

Former Member
0 Kudos

Thanks Jose,

Out two, which should be preferred (technically)...or it just the matter of choice?

Former Member
0 Kudos

Hi,

I prefer to use java mapping. It is more comfortable for me.

Regard

Ivan

Former Member
0 Kudos

Hi Ivan,

Since you have enter the xslt mapping in Message Interface mapping and both Message Interfaces (target and source) are tied with the message type. And in message type you have fixed schema, do you think it still possible to use xslt mapping to generate some of the target nodes dynamically (the nodes which are not part of MessageType/DataType)....thx?

Former Member
0 Kudos

Hi,

Yes it is possible because PI does not have any xsd validation by default.

Regards

Ivan

Former Member
0 Kudos

Thanks and one last question -

What could the best way to test XSLT testing...e.g. Is there a way to test XSLT mapping within PI ...like there is test for Message Mapping...or something similar?

Former Member
0 Kudos

Yes,

You can do it in your interface mapping.

Regards

Ivan

Answers (0)