Skip to Content
avatar image
Former Member

Create Multiline Order in reference to Contract line item using custom BAPI

Hello,

We are using the 'BAPI_SALESORDER_CREATEFROMDAT2' to create an order where the customer uses the contract to place a single line order through a web interface. The issue is they wish to create a multiline order that references the same contract and our current ZBAPI that calls the BAPI mentioned above is that it will only create a single line order. I am the functional analyst on this 'project' but don't have the ABAP resource strong enough to code this without specific instructions. I am not looking for the exact code but if you can give me some pointers on how to explain what is needed to a rookie ABAP developer that would be great. Here is what we currently have created and all I need to do is make it so we can do multiple lines

BAPI.txt.zip (4.5 kB)
Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Sep 25, 2014 at 11:14 AM

    Hi Grant,

    I can see a Loop on ORDER_ITEMS_IN. Where is this getting populated from,as I could not see it being populated earlier in the code.

    Regards,

    Shashi Thakur

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi Grant,

      I think that is the probable reason, as from the code it is not clear how the Loop would even run if the particular structure ORDER_ITEMS_IN is empty or it will run once if it has only one entry for the item populated before coming inside this BAPI.

      Regards,

      Shashi Thakur