cancel
Showing results for 
Search instead for 
Did you mean: 

Create Node (Mapping)

Former Member
0 Kudos

Hi

My Req is as below

Source

row (0..unbound)

matnr

movetype (101)

weight

Now target should be generated based on the move type 101 , for each move type 101 i should generate 101 as usual and 261 record as below

item(0..unbound)

matnr

Movetype (101)

weigth

item

matnr

Movetype(261)

weigth

So for n occurence of 101 i should make n occurence of 261 , Matnr , movetype details of 261 should bwe corresponding 101 record details

rgds

srini

Accepted Solutions (1)

Accepted Solutions (1)

former_member200962
Active Contributor
0 Kudos

Hi,

Use the below logic:

Duplicate the target item node

For these two item nodes check if the Movetype is 101....if yes then map it to the Source item node

So your First item will get created if source Movetype is 101 and same for Second item node...i think that you may need to play with the Context of the source fields to achieve this.

regards,

Abhishek.

Former Member
0 Kudos

Hi Abhishek,

Working with same template .

lemme me check if it is through

Srini

siddhesh_pathak4
Contributor
0 Kudos

Hey ,

Check out if below UDF is working for your requirement. You have to use it in all you source items (like matnr n others).

for(int i=0; i<a.length(); i++)
 {
     if (b<i>.equals("101"))
     result.addValue(c<i>);
     if(b<i>.equals("261"))
     result.addValue(c<i>);    

 }

Pass a as item, b for qualifier and c for your source item.

Answers (4)

Answers (4)

former_member581827
Participant
0 Kudos

Hi,

First duplicate the structure of target another time and then genarate structure for for movment type 261 only when source move ment type is 101 and as many times as movement type 101 occurs by using "Use One As Many" Function.

Regards,

Chandra.

Former Member
0 Kudos

thq

all

srini

former_member581827
Participant
0 Kudos

Hi,

Have you tried using one as Many function.

Try using the function.

Regards,

Chandra.

Former Member
0 Kudos

Ur requiement is not very clear could u please eloborate more ?

Former Member
0 Kudos

Hi,

I think in design while creating datatype u can specify default value for particular node. Please mention 251 value to Move type

and in message mapping create that node if value of move is 101.

like

move----

.............equals-createif--movetype

const(101)--

lets see if it works.

Regards,

Manisha