Skip to Content
avatar image
Former Member

Synch SOAP scenario - access request data as part of response mapping?

Hello experts,

I have a synch SOAP scenario which is working but I want to improve the error handling.

Under normal situation I send the SOAP request and the remote web service responds with a given message structure which includes my invoice number as a key field. I then create an IDOC with this number and processing is great.

However, sometimes there is an error response from the web service which follows a different message structure and does not include the invoice number :-(

There could be many reasons for this error such as a field was missing or wrong format or even we ran out of prepaid web service calls (this is to get a government approval of invoice which we pay for in groups of approvals).

When they respond with an error I would like to send this information in IDOC to SAP, but I have no invoice number to tie the response to. Therefore the information is kind of useless in ERP. Is there a way in PI for a response message to reference the synchronous request data we sent to the web service in the first place?

Many thanks for your ideas,

-Aaron

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Best Answer
    Sep 11, 2014 at 02:55 PM

    Hi Aaron,

    If you have the invoice number in the request message then below blog will be helpful

    Insert value from Request message to Response message using GetPayloadValueBean and PutPayloadValueBean

    regards,

    Harish

    Add comment
    10|10000 characters needed characters exceeded

  • Sep 12, 2014 at 05:45 AM

    Hi Aaron,

    In your request mapping use dynamic configuration to place the invoice number and then in your error response mapping use dc to retrieve it.

    Regards,

    Mark

    Add comment
    10|10000 characters needed characters exceeded

  • Sep 12, 2014 at 05:59 AM

    Hi Aaron,

    Also you can define static variables Sharing data between message mapping in PI 7.1

    About Mark suggestion you have an interesting Adarsh Dhingra's blog here Sharing data between two message mappings through Dynamic Configuration

    I think the better way is to use the Harish approximation because is the solution more standard.

    Regards.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Sep 12, 2014 at 02:53 PM

    Thanks guys these are super helpful suggestions. I will try some approaches and close the thread when I choose one.

    Add comment
    10|10000 characters needed characters exceeded