cancel
Showing results for 
Search instead for 
Did you mean: 

conditional checking in message mapping does not work

pohian_koh
Explorer
0 Kudos

Hi Experts,

I've been troubled with the message mapping for sometime. Hopefully someone here can help me out.

Scenario:
Payext IDOC > MQ
The requirement is to check if the there's any PARVW = Z exist in each idoc, if yes then Address info should come from the particular node.
Otherwise pick the 1 where PARVW = B.

Sample:

The requirement sounds simple, but i'm not getting my expected value no matter how i tried.
With 1 idoc segment the value is populated correctly. But if there's a 2nd idoc segment, it will throw error with some mandatory field under address node does not have value in queue context.


Please help.

Regards,
Koh

Accepted Solutions (1)

Accepted Solutions (1)

former_member190293
Active Contributor

Hi Koh!

Parameter "Keep SUPPRESS Values" for IfWithoutElse function must be set to "off" (unchecked) for both cases:

Elements PARVW and STRAS should be moved to IDOC context:

Mapping result:

Regards, Evgeniy.

pohian_koh
Explorer
0 Kudos

Hi Evgeniy,

Thanks!!!.
I've tried your solution and it works perfectly.
Could you please advice why the ordinary way of checking does not fit in this case? Eg: ns0:Ctry=ifWithoutElse(stringEquals(/ZPAYEXT/IDOC/E1EDKA1/PARVW, const(value=BE)), /ZPAYEXT/IDOC/E1EDKA1/LAND1, keepss=false)

Thanks
Best regards, Koh.

Answers (0)