Automate

 View Only
  • 1.  Adding a Loop to a BAPI

    Posted 20 days ago

    Hi - kindly show me how to add a loop in the attached BAPI's.

    If I add the loop as per below image, only one of the records are added.

    image



    ------------------------------
    Renette Nienaber
    Mrd
    VIVO ENERGY SOUTH AFRICA (PTY) LTD
    ------------------------------

    Attachment(s)



  • 2.  RE: Adding a Loop to a BAPI

    Employee
    Posted 20 days ago

    Hi Renette

    Great you're trying out BAPIs! :)

    Typically you will need to include all of the fields in each table that are needed to define a new bank - not just part of the fields.  

    Best Regards,

    Sigrid



    ------------------------------
    Sigrid Kok
    *Precisely Software Inc.
    ------------------------------



  • 3.  RE: Adding a Loop to a BAPI

    Posted 18 days ago

    Thank you Sigrid, I am able to create a loop to download existing with BAPI_BUPA_BANKDETAILS_GET but can't seem to get a loop to work for the Remove or ADD. It will only add or remove the last record.

    Can you kindly add the loop for me in the remove script. I would like to use it in a repeating group.

    Regards,

    R



    ------------------------------
    Renette Nienaber
    Mrd
    VIVO ENERGY SOUTH AFRICA (PTY) LTD
    ------------------------------

    Attachment(s)



  • 4.  RE: Adding a Loop to a BAPI

    Employee
    Posted 17 days ago

    Hi Renette

    Finally found some time to look at these function modules/bapis.

    It looks like the structure doesn't support adding multiple bank ID's - i.e. there's no table for BP and bankdetailid. If you run it with a loop, it will only add one. I tried and left off the bank detail id in the input and downloaded the one generated - it only generated one.

    It looks like the remove is the same BAPI_BUPA_BANKDETAIL_REMOVE

    So while both are working on one bank, you can import it into the form as a repeating script - my example is for BP company codes for a customer

    You get a repeating group in the form schema

    then you can add it to the form as a repeating table or repeating section.

    Sorry about the BAPI, but you can still do multiple in the form.

    Hope that helps. If I missed your issue, please provide details. :)

    Best Regards,

    Sigrid



    ------------------------------
    Sigrid Kok
    *Precisely Software Inc.
    ------------------------------