cancel
Showing results for 
Search instead for 
Did you mean: 

IDOC Segments Mapping issue in PO 7.4

Former Member
0 Kudos

Hi Guys,

I have a requirement where one of my IDOC segment will be mapped from source structure 5 times. The target structure should be dynamically filled.

Source Structure

<E1XXX14 SEGMENT="1">

</GTBDR>

</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

</GTBDR>

</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

</GTBDR>

</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

</GTBDR>

</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

</GTBDR>

</AFNTR>

</E1XXX14>

In the target I should get the below value into my IDoc structure

<E1XXX14 SEGMENT="1">

<GTBDR>011</GTBDR>

<AFNTR>ABC</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

<GTBDR>007</GTBDR>

<AFNTR>PQR</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

<GTBDR>080</GTBDR>

<AFNTR>XYZ</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

<GTBDR>900</GTBDR>

<AFNTR>RST</AFNTR>

</E1XXX14>

<E1XXX14 SEGMENT="1">

<GTBDR>319</GTBDR>

<AFNTR>WXY</AFNTR>

Thanks in Advance!

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member186851
Active Contributor
0 Kudos

Hello Waseem,

Please elaborate more on the requirement.

Source and target uses same IDOC?

Populate values dynamically means which values the one coming from source or random?

Former Member
0 Kudos

Target is an IDoc structure and Source is manually designed .

From the source the value will be empty we need to populate it dynamically but the values are fixed as mentioned above.

former_member186851
Active Contributor
0 Kudos

Hello Waseem,

Just go for Constant or map with default like.

Constant

Constant--------><GTBDR>

Example

011--------------><GTBDR>

or Map with Default

source                                            Target

<GTBDR>---Map with Default--><GTBDR>

Example

<GTBDR>----------Map with default----><GTBDR>

                               value-011

Former Member
0 Kudos

Thanks Raghu for replying!!!

I can't use both.

My problem here is in the source structure this segment is occurring 5 times and I need to map one value each time to target structure .

former_member186851
Active Contributor
0 Kudos

Waseem,

Right click on the target root node in the mapping,select duplicate subtree for E1XXX14 for 5 times and map corresponding values to each E1XXX14 segments.

Try this else lets go with UDF or other functions.

Former Member
0 Kudos

Thanks again Raghu, I did try your option but below error pops up while saving

So what do you suggest me now?

former_member186851
Active Contributor
0 Kudos

Hello Waseem,

I jus tried your case for Orders IDOC.

Duplicated E1EDK05 in the target structure and i am gettign the desired output.

Did you do any changes in the mapping?

Former Member
0 Kudos

So I am duplicating the segment here will I have any issues on R/3 side while posting IDocs is my question now!!! Just want to know.... However I will try this from my end.

former_member186851
Active Contributor
0 Kudos

Hello Waseem,

There wont be any issues,

The segment is having the occurrence 0-unbounded.Its like sending multiple values to that segment.