cancel
Showing results for 
Search instead for 
Did you mean: 

Idoc to file

Former Member
0 Kudos

hi all

Am doing an idoc to file scenario. In this from idoc i wanna map to a structure like this

<E1KNA1M>

structure1

</E1KNA1M>

<E1KNA1M>

structure 2

</E1KNA1M>

Is it possible to have a structure like his in xi. Like nodes with same name and different structure. PLz help

Accepted Solutions (0)

Answers (5)

Answers (5)

Former Member
0 Kudos

Hi,

Yes it can be possible .. provided if you have the node occurrences multiple >0 or 0.. unbound..

Only thing is you have to duplicate the node and map source to target with MM functions or as per your requirement..

I hope you got it or ..

please explain bit more with your example ..

Regards

Chilla..

Former Member
0 Kudos

Hi Sumayya,

Can you please elaborate your requirement.

Bcz you can never create a Data type with same node names.

Regards

Gopi

Former Member
0 Kudos

my source structure is

<EDI_DC40>

structure1

</EDI_DC40>

<E1KNA1M>

structure2

</E1KNA1M>

from this i ve to create the target as i explained above

Former Member
0 Kudos

Hi Sumanya,

see your target structure of one node having 2 different structure is not possible in XI.........

so you can have a target struc like below:

<CONTROL_DATA>

structure1

</CONTROL_DATA>

<E1KNA1M>

structure2

</E1KNA1M>

Thanks,

Rajeev Gupta

prabhu_s2
Active Contributor
0 Kudos

U cannot have two strucutre with the same name...say u have this strucure in a data type source_DT...u cannot create the same data type but u can copy the sub nodes of source_DT totarget_DT and use it...the same applies for ur scenario also

Former Member
0 Kudos

But from xi the output is read by MDM server. So it requires this format. and throwing error is some other name comes for that node

prabhu_s2
Active Contributor
0 Kudos

if u want ur target have the same strucutre as of ur source then u can skip mapping. just use the source idoc alone. mapping can be skipped if no manuplations are done and source and target have the same data type.

so thru this way u have target and soruce share the same data type...or if u got some manuplation to be done use the same soruce structure in the target messaeg type also !!!

Message was edited by:

Prabhu S

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

Use Java Mapping.

Java Mapping does not validate the output of the mapping against the correspondiong Target Message Type.

Regards

Bhavesh

Former Member
0 Kudos

Hi Sumaya,

Ok......then create a target struc like below:

<CONTROL_DATA>

structure1

</CONTROL_DATA>

<E1KNA1M>

structure2

</E1KNA1M>

do mapping...... generate this target output....... now create a J2EE adapter module by seeing the below link:

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/3bdc14e1-0901-0010-b5a9-a01...

in this module, change the name of node CONTROL_DATA to E1KNA1M.... then in the reciever file adapter call this module.........then your requiered target file for MDM will be generated as the below structure:

<E1KNA1M>

structure1

</E1KNA1M>

<E1KNA1M>

structure 2

</E1KNA1M>

Thanks,

Rajeev Gupta

Former Member
0 Kudos

is there any already exixting module for doing this'

prabhu_s2
Active Contributor
0 Kudos

are u going for any mapping...chaging the contents for the targfet system? if not then u can skip this mpaping part itself.

Former Member
0 Kudos

No am not using any mapping. the message that reache s the channel is

<EDI_DC40>

structure1

</EDI_DC40>

<EK1NA1M>

structure 2

</EK1NA1M>

So i wanna write a module configuration which will rename the first tag as <ek1na1m>.

Former Member
0 Kudos

Hi Sumayya,

"Is it possible to have a structure like his in xi. Like nodes with same name and different structure"- you want a node having 2 Different structures in XI - this is not possible ......a node can have only one structure for it.......you can rename the other node.....and you can change the way of processing for it in your target system.

Thanks,

Rajeev Gupta

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

><i>Is it possible to have a structure like his in xi. Like nodes with same name and different structure. PLz help</i>

This is not possible

if you try to create a Datatype of this sort you will get an Error,"Node already exists"

Regards

Bhavesh

Former Member
0 Kudos

is ther any means to do this

Former Member
0 Kudos

give one main structure and include sub-items under it . this should help you.

Regards

Sreeram.G.Reddy

prabhu_s2
Active Contributor
0 Kudos

ur soruce:

<E1KNA1M>

structure1

</E1KNA1M>

<E1KNA1M>

structure 2

</E1KNA1M>

ur target

<root>

<E1KNA1M>

structure1

</E1KNA1M>

<E1KNA1M>

structure 2

</E1KNA1M>

</root>

the only diff u will find is the change in the root node

prabhu_s2
Active Contributor
0 Kudos

yes....u can have the same idoc struct for the target aswell....