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

Problem with created assets via BAPI without COMMIT

Hello,

I have created few assets using BAPI_FIXEDASSET_OVRTAKE_CREATE, but I didn't know that I need to call BAPI_TRANSACTION_COMMIT before every asset creation.

Now my code is running ok but I have a problem with the assets created when I forgot the commit instruction. The asset's aren't in the database but they are "somewhere" because I can't use the id's that of those assets aren't available.

How can I commit the work to get the assets fisically to the database??

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

3 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Nov 30, 2007 at 02:35 PM

    This is unfortunately a side effect of using number ranges (which I assume asset creation does). Even if the bapi does not do a commit, the number assigned has been used and you cannot use it again.

    The asset in fact does not exist anywhere.

    Rob

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 30, 2007 at 12:42 PM

    up... I will reward!!!

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      If you r running BAPI through tcode BAPI or from SE37 then you will have to run BAPI_TRANSACTION_COMMIT FUNCTION as below.

      display function and

      GO TO Function module ->Test->Test Sequences

      enter your BAPI function in first line and in second line enter

      BAPI_TRANSACTION_COMMIT FUNCTION

      after executing this you will get data in table.

  • author's profile photo Former Member
    Former Member
    Posted on Nov 30, 2007 at 12:52 PM

    hi buddy ..

    techinically if u dont commit and exit the transaction the default action is rollback... this mean none of the information has touch the database..

    But the is a possability that such update program may exist in transaction SM13.. there you will find pending update program..

    on first screen enter client and the user name of the person who run the transaction ..

    No Points Plz

    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.