cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping Doubt

Former Member
0 Kudos

Hi Experts,

Below is my input data structure.

ST

   -->S_AK1

           -->D_28

  --->G_SAK2

           -->S_AK2

                   --->D_329

Mapping logic:

If AK2 exists, pass D_329 else pass D_28

I have mapped like this

D_329(context as S_Ak2) ---> exists ---> if (then - pass D_329) ---> Target

                                                                 else (pass D_28)

The issue is if i send only AK1 data with out AK2, its passing null..can you help on this mapping logic.

Accepted Solutions (0)

Answers (1)

Answers (1)

Harish
Active Contributor
0 Kudos

Hi Sruthi,

try the below logic

D_329(context as ST) ---> exists ---> if (then - pass D_329) ---> Target

                                                                 else (pass D_28)

regards,

Harish

Former Member
0 Kudos

Thank you..I tried it..but the thing is, I may get multiple AK2 and Ak1 values in one ST so if I change the context as ST, I dnt think it will work for all values in AK1/AK2.


Former Member
0 Kudos

Instead of exist try as below.

D_329(context as S_Ak2) ---> Mapwithdefault --equals -->Not-->Constant (Blank)---> if (then - pass D_329) ---> Target

                                                                 else (pass D_28)

Former Member
0 Kudos

Thank you.

Tried still its not working for all the scenarios.

Harish
Active Contributor
0 Kudos

Hi Sruthi,

If occurrence of D_329 is 1:1 or 0:1 then try the below logic

D_329 (context as S_AK2) ---> map with default --> equals blank not ---> if (then - pass D_329 (context of AK2)) ---> Target

                                                                 else (pass D_28 (context of AK1)

Use split by value before target field.

Now the problem comes when occurrence of AK1 and AK2 is different.

If it is not work then provide your input XML to give you exact mapping.

Thanks,

Harish

praveen_sutra
Active Contributor
0 Kudos

hi Sruthi,

Yes it will not work.

rather try this.

S_Ak2---> exists ---> if (then - pass D_329) ---> Target

                                                                 else (pass D_28)

this should work.

thanks and regards,

Praveen T