on 04-09-2014 6:17 AM
Hi All
We have configured alert notification through PI Alert configuration and we receive the notification email containing message id whenever a message is failed in the integration server.
We want to modify the default email body so as to include dynamic data from the message fields, whenever a message failes the notification email contains the whole message either in XML format or other.
I would appreciate if anyone can help me remaining in SAP PI system itself. We have SAP Netweaver PI 7.1, sp5.
Regards
Sidra
Hi Hasan
The standard alert mechanism will not able to provide you the solution of your requirement. It does not have any functions which can allow to you get the payload data and attach in the alert email.
Only one solution is coming in my mind and I don't think we have other options
1. You need to send all the alert email to a generic mail address.
2. Create one more mail-to-mail scenario where the sender mail adapter will read the alert emails.
3. Use mapping in PI which will read the message id from mail, then call a function module in abap
which will return the payload data from message id.
Below are sample code
CALL FUNCTION 'SXMB_GET_MESSAGE_PAYLOAD'
EXPORTING
im_msgkey = ls_msgkey
im_archive = ' '
im_version = '000'
IMPORTING
ex_msg_bytes = lv_bin_xml
EXCEPTIONS
not_authorized = 1
no_message = 2
internal_error = 3
no_payload = 4
OTHERS = 5.
4. Send the payload data as attachment to the target mail group which will receive the final alert emails.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks Indrajit
I tested the function in SE37 and i decoded the return string by ECATT_CONV_XSTRING_TO_STRING
but the value returned was only the first line of my XML message, Is is supposed to be like this or 'SXMB_GET_MESSAGE_PAYLOAD' should return the whole XML message?
Thanks for your support.
Regards
Sidra
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
81 | |
10 | |
10 | |
9 | |
7 | |
6 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.