Skip to Content

Parsing XML File for IDOC and BAPI

Hi Experts,

I got One new requirement.

We are getting One file from sender system that is XML File.The File will be parsed in to 2 Files for SAP IDOC and BAPI.

How to Achieve this Requirement ??

What are the objects we need to design and Configure in ESR and ID.

Can Any One tell me the procedure which i need to follow.

File---->PI---->Idoc and BAPI

It will helpful to me a lot.

Thanks and Regards,


Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

4 Answers

  • Best Answer
    Jun 04, 2015 at 12:03 PM

    You have 2 option, Interface split and Mapping based message split.

    Defining Message Splits - SAP NetWeaver Process Integration - SAP Library


    1 outbound interface: sender to PI

    2 inbound interface: PI to IDOC & PI to BAPI.

    in case of interafce split: 2 message mapping for each interface (Source to IDOC and source to BAPI)

    in case of Mapping based message split: 1 message mapping (Source to Messages)

    Your mapping Traget structure will look like this,










    Two channels for each inbound interface.

    Use extended receiver determination in case of condition based receiver determining.

    You will get option to choose mappings accordingly for multiple receivers in interface determination.

    For more details regarding ESR and ID objects, refer above link.

    Add comment
    10|10000 characters needed characters exceeded

  • Jun 02, 2015 at 08:13 PM

    Hi Ravi,

    As you need to parse the file to the RFC interface and IDOC interface, you will have two different XMLs. You can try with multi-mapping:…

    I'm not sure the ABAP IDOC adapter is supported in multimapping, if it is possible i would talk with ECC developer in order to wrap the IDOC with a RFC, and you will have two RFCs, totally feasible with multimapping.


    Add comment
    10|10000 characters needed characters exceeded

    • But RFC is by default for Synchronous.

      How to use RFC as asynchronous i am not expecting the Response or

      While taking BAPI at Message mapping shall we take only the Structure with out response.

      Like Assume BAPI_Material_ExistingCheck after importing BAPI, we use this in Message mapping at that time it will ask



      so at that time we will take the structure with out response



  • avatar image
    Former Member
    Jun 02, 2015 at 10:23 PM

    The blog that Inika has provided is a very good to follow. in addition to that, please go through the below thread where multimapping for idocs are possible(check Eng Swee answer)



    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Jun 04, 2015 at 11:39 AM

    Hi Ravi,

    Yes, as suggested above, you can go for multi mapping(1:2), one file which needs to be converted to IDOC & BAPI structure.

    Regarding Development approach, just follow normal development approach only but in case of receiver just you need to include those two in your operational mapping and message mapping.

    In ID part, you need to define two receiver agreements.



    Add comment
    10|10000 characters needed characters exceeded