cancel
Showing results for 
Search instead for 
Did you mean: 

Error to IDOC Sender

former_member192105
Participant
0 Kudos

Dear Experts,

I have a requirement to send error information back to the IDOC Sender. The scenario is IDOC --> PI --> TargetSystem (ASYNCHRONOUS).

If there is an error in processing within SAP PI, then the error should be propagated to the SAP system (IDOC), so that the Business can take note of the error.

As far as I know, we can configure Alerts in SAP PI and in case of an error the recipient will get the alert message. But how to send the error message back to sender in case of an IDOC

I do not want blogs on how to configure alerts in ALRTCATDEF

Thanks.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Abishek,

IDoc or not, sending an alert is always possible. But your question is not clear, with sender we usually identify a system, although I think you mean the person that triggered the IDoc, ie. someone who created a SalesOrder, which was then sent to PI.

Check if you have some sort of Creator UserID in the IDoc, and if not, you will need a custom IDoc type where you send this serID along. With this UserID you can do a lookup in the sender system, to retrieve the email-adress in the User Master Data record. Then use this email adress to send an alert, or use the SMTP adapter to send a message.

Hope this helps.

kr,

Peter Glas

former_member192105
Participant
0 Kudos
although I think you mean the person that triggered the IDoc, ie. someone who created a SalesOrder, which was then sent 
to PI.

Yes, this is what is required.

With this UserID you can do a lookup in the sender system, to retrieve the email-adress in the User Master Data record. 
Then use this email adress to send an alert,

How exactly the lookup will be done? I have a message processing running in SAP PI, suddenly something goes wrong (lets say there is a mapping error) and the processing stops there. Now how to do a lookup (from where)? Configuring a fixed recipient in ALRTCATDEF wont work as we dont know who will trigger the IDOC!

Any reference on how to perform lookup when message fails in XI/ PI will be helpful.

Thanks.

former_member192105
Participant
0 Kudos

As of now a Distribution List will be created and the errro will be send to this DL.

Thanks.

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

You can always generate alert in this case.

One approach I can think is you can use BPM, where the steps will be like

Receive(IDOC) ->SyncSend(Send to your target system and wait for the ack)-> then use Switch block and based on return code(if 0, send to target or generate alert).

Divyesh Vasani