cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic Determination of Target Messge Type (IDoc)

Former Member
0 Kudos

Hello,

we have a IDoc - HTTP scenario. A SYSTAT01 IDoc should be sent back to the sender system setting the status depending on the http response.

The basic scenario works fine, however depending on the value of one field there should be either a STATUS or ZSTATUS message type be sent back. Both are based on the SYSTAT01 IDoc structure and there absolutely no difference in the mapping logic. The two differet message types are used to handle inbound processing in SAP differently.

Question now is, whether I can set the output message type dynamically in ONE message mapping. I tried to set the field MESTYP in the control header, but this does not work, as the MESTYP obviously is always set according to the imported type.

Of course it would work using two different mappings, but I would rather handle ii

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

AFAIK i know you need to use the two mappings for your requirement based on the condition of the return type...from the HTTP Request...

HTH

Rajesh

Answers (1)

Answers (1)

MichalKrawczyk
Active Contributor
0 Kudos

Hi,

you cannot change message type in the mapping

but you can have two target messages in one mapping and fill only one of them

Regards,

Michal Krawczyk