cancel
Showing results for 
Search instead for 
Did you mean: 

Receiver determination issue

Former Member
0 Kudos

Hi all,

I have a typical scenario, where the message mapping is such that a particular child node in the target will get mapped (created) only if certain logic gets satisfied. Otherwise the child does not get created.

Now, my problem is - I want to send this message to receiver only if this child node exists. (There is no point in sending empty message to receiver)

The condition in receiver determination can use only source message since message mapping is executed after the receiver determination.

Can anyone pls help ?

Thanks,

- Shankar.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Shankar,

I think you could you use the <a href="http://help.sap.com/saphelp_nw04/helpdata/en/43/a5f2066340332de10000000a11466f/frameset.htm">Enhanced Receiver Determination</a>.

There you have to create a mapping that decides which is the receiver depending on some conditions in the mapping (the existence of that field).

Then in receiver determination, you have to flag the value "<i>End Message Processing Without Error (Restart not Possible)</i>" If a receiver is not found.

Kind rgards,

Sergio

Former Member
0 Kudos

Sergio,

my requirement is little different. In my case, <b>the receiver is fixed.</b> The only question is whether to send the messge to it or not, depending on whether a particular node exists in the target message. So I guess, enhanced receiver determination may not be helpful here.

Regards,

- Shankar.

Former Member
0 Kudos

Hi Shankar,

I'm not sure if you can do that with normal condition in receiver determination

I think this can be done with a condition, (that is the logic you use to decide wheter to create the node or not), just it depends on how much complex is the condition.

If the condition is too complex I think you cannot use just the condition editor to define it.

But consider that in any case enhanced receiver determination can be used even if you have a fixed received.

You can view it in a different way, you do not have a fixed receiver, your receiver is "A" if condition is true and your receiver is "null" if condition is not true.

Is'nt this your requirement?

So I would say assign the receiver in the mapping if the condition is fulfilled, otherwise do not assign a receiver, this will result in a "no receiver found" and you can stop the message processing.

Regards,

Sergio

Former Member
0 Kudos

Seems good.. But do I need to have a separate message type <b>'receiver'</b> to hold the dynamic list of receivers ?

Say I have mapping A -> B, where A and B are message types. Now for receiver list, suppose there is third message type say R, then my new message mapping would look like -

A -> B, R

Did you mean the same thing ? BTW, the mapping is too complex and gets repeated across many namespaces, so changing it everywhere is a nightmare.

Regards,

- Shankar

Former Member
0 Kudos

Hi Shankar,

yes, as SAP documentation says:

<i>

During the definition of the interface mapping, you assign the abstract message interface ReceiverDetermination as the target interface. The message interface ReceiverDetermination is in the Integration Repository in the software component SAP BASIS (namespace http://sap.com/xi/XI/System).

The message interface uses the message type Receivers and the data type Receivers. The data type Receivers describes a list of receivers</i>

Regards,

Sergio

Former Member
0 Kudos

Shankar,

please note that you have two mappings in this case:

A->B

A->R

it is not A-> B,R

Regards,

Sergio

Former Member
0 Kudos

Thank you Sergio for your help.

Regards,

- Shankar.

Former Member
0 Kudos

use the function exits. It checks whether the source element is occuring or not.