Skip to Content
author's profile photo Former Member
Former Member

Execute BAPI again on error

Hi Experts,

I have a BAPI and I need to execute this BAPI again after a particular waiting time (e.g 10 sec) once it fails.

How can I achieve this functionality?

Any helpful entry will be rewarded.

Warm regards,

Raman

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Posted on Dec 03, 2007 at 08:30 PM

    You can read the RETURN table and if the error is there you can use the WAIT syntax to wait for some itme.

    Like:

    WAIT UP TO 10 SECONDS.

    Regards,

    Naimesh Patel

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Dec 03, 2007 at 08:35 PM

    Why do you want to wait?

    Rob

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Dec 03, 2007 at 09:02 PM

    In most cases, you get this kind of issues when there is a lock on the object that you trying to update or if you are creating and updating the same object in the same program flow. If it is the first case, introduction of a DO... ENDDO may help. In the later case, BAPI_TRANSACTION_COMMIT with WAIT = 'X' after the create call helps.

    DO.

    call bapi.

    if there is an error in the return messages.

    continue.

    else.

    exit.

    ENDDO.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.