Wednesday 20 April 2022

Mass activation and mass deletion a la carte using ADT

The problem

Today I had to delete 1385 repository objects that had been created as part of a customer workshop.

The problem was that all these objects have been created in 70 packages.

On the other hand I had to perform a mass activation for the objects that are part of the SFLIGHT sample project and which live in the /DMO/ namespace, but unfortunately I had played around with the generation of RAP objects in the Z-namespace and my transport request did not only contain the objects of the /DMO/-SFLIGHT objects but lots of other (partly inconsistent) stuff.

When clicking on mass activation ADT offers you to activate the objects that are part of a transport request but there is no option to right click on a package and all the objects of that package and its sub packages being generated.

ABAP Repository Trees to the the rescue

But it took unfortunately a while and it did not come to my mind immediatly that I had already worked with the tool set that could solve my problem.

Nethertheless the ABAP Repository Trees in ADT have been my best friend today.

When working with ADT you can create a new ABAP repository tree when you right click on your project and select New –> ABAP Repository Tree from the context menu.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials
Create a new ABAP repository tree

Here you can start with a tree template or with a blank tree.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials

I will use the blank tree and select all objects where the name starts with ZRAP500 which was the “namespace” we recommended to use our workshop participants.

Please note that you can also use the Object Name Pattern without any property filter.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials

Similarly it is possible to create an ABAP repository tree that only shows objects where the name starts with /DMO/.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials

This allows me to select all objects that have been imported via ABAP Git from the SLFIGHT Git Repo though I accidently have used the same transport request for several other things, so that by selecting the transport request I would have to activate lots of inconsistent objects which would not work.

Or it helps me to simulate a feature that I am missing in ADT, namely the mass activation of all objects that are part of one package (and its sub-packages).

Using the following selection it is possible to select all objects that are part of the package ZRAP100_002.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials

Mass deletion


Using this new ABAP Repository View I am now able to select all the ABAP repository objects that have been created by the workshop participants in one list.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials

Since the deletion process does not whipe out all objects immediately the new view at least helps us to identify the remainging objects.

When deleting lots of objects you might also be asked by ADT to provide a transport request for objects that are currently not assigne to one.

Here there is a feature available in ADT that allows you to select just one transport request for all objects that have none rather than having to click multiples times.

SAP ABAP Exam Prep, SAP ABAP Career, SAP ABAP Skills, SAP ABAP Jobs, SAP ABAP Guides, SAP ABAP Tutorial and Materials

Activate all objects of SFLIGHT


When you have imported the objects of the SFLIGHT project (and if you have been to lazy to work with new  task lists or task list objects) you can create a view that only shows objects that are part of the namespace ZRAP500*

Using the SFLIGHT View mentioned above it is possible to select the objects that have been imported via GitHUb.

Source: sap.com

No comments:

Post a Comment