Skip to Content

The Problem


A bizarre incident occurred the other day: we discovered that a complex, custom (ABAP) WebDynpro – which has been in Production for years – had disappeared from our Development client.

The object exists in Production and Test, but not in Development. Even more bizarre, there was no transport in DEV recording that it had been deleted.

Could it be a technical glitch? There’s none that I can think of.

Was it perhaps a rogue agent? Would a developer really delete a program and then cover his/her tracks by deleting the transport as well? Unlikely.

We’re still not sure. Anyway, we had to figure out a way to restore the program quickly, as urgent maintenance was required.

The BASIS guys suggested transporting the program back from Test to DEV, but that just seemed too hard.

The Solution

We then discovered a much easier way, which I am sharing in this document. It hinges on the realization that even when you delete a program, the version history lives on in the database.

Here’s the recovery procedure (for a simple ABAP program):

  • transaction SE38: create a new program object with the _exact_ same name, and save it (you will be prompted to create a new transport)
  • in the ABAP Editor, choose menu item Utilities > Versions > Version Management
  • select the most recent version (obviously not today’s) and click on the ‘Retrieve’ button
  • press the ‘Back’ button – you will see now that all your code has been restored πŸ™‚
  • press ‘Save’ and Activate
  • Also restore the text elements; these have a version history as well.

For ABAP WebDynpro, the procedure is a bit more complex, because multiple objects are involved.

You need to re-create:

  • the Web Dynpro (in SE80)
  • the Component Controller
  • the Windows
  • the Views
  • the Interface Controller
  • the Web Dynpro Application
  • etc

For each object the procedure is basically the same: recreate an object with the exact same name, and retrieve the most recent version. If it has no version history (like the WebDynpro Application), then you just create it manually by copying whatever is in Production.

In all cases, you should have a copy of the program object open in Prod, and do constant eyeball comparisons until you are sure that everything matches. To be safe, you might even want to use version management to do a remote compare of the finished product (use the “REMOTE comparison” button in SE38:  Utilities > Version > Version Management)

Of course, this only works if your object was transported at least once, OR you executed the ‘Generate Version’ function  (SE38 Utilities > Versions > Generate Version). The latter applies to local objects as well.

Once all this is done, you can commence your urgent maintenance.

Happy ending πŸ™‚

PS: a similar strategy can be used to retrieve deleted workflows as well:


To report this post you need to login first.


You must be Logged on to comment or reply to a post.

    1. Paul Bakker Post author

      Well, since you ask, I actually encountered another similar issue today (at another client). Some ‘goose’ had deleted a top-level function group Z_VT_DIALOGS, but all its includes & function modules still remained.

      In this case all I had to do was recreate the function group (in SE80). Immediately, all the includes automagically reattached themselves to it. No version history retrieval required.



  1. Former Member

    Do we have to do this everytime be4 we delete our program :-

    SE38 Utilities > Versions > Generate Version???

    Does that  effect the program by anymeans??

    Anyway thanks for the post paul.

    1. Former Member

      Hi Amarantha,

      This is for retrieving programs deleted by accident. You don’t have to Generate Version if you are deleting it intentionally.

      Anyway, Generate Version is only useful if it’s a local object A version is saved every time a transport is done.



    1. Former Member

      Before this we need Generate Version then only we can able retrieve it.

      Only if it’s a Local object ($TMP). If it gets transported then a version is saved automatically.

  2. Former Member

    Dear Paul,

    In normal ABAP program SE38, we can download program from Quality or Production System, Go to Utilities and More Utilities and Download and save it in .xml format and upload in Development Systems using above procedure except download use upload with previous name and then also we can recovery the program .

    Over all its is Nice Article Paul πŸ˜€ πŸ˜€

    Thanks and regrads,

    Madhukumar L

      1. Former Member

        Ya, i do agree Paul’s Approach is simpler,But what every i have mentioned above is also one more way to fulfill to requirement.

        Just i have mentioned alternate way to fulfill the requirement.


Leave a Reply