Financial Management Blogs by Members
Dive into a treasure trove of SAP financial management wisdom shared by a vibrant community of bloggers. Submit a blog post of your own to share knowledge.
cancel
Showing results for 
Search instead for 
Did you mean: 
gajendra_moond
Contributor
Introduction

This document will explain how to delete data selectively in a BPC model.

Software Components

- SAP BPC 10.0 on SAP NW BW(7.31)

- EPM Addin - Version 10 SP21 .NET4

Requirement

SAP BPC provides provision to clear data through data manager package or script logic. However, what each of these approaches do is that they zero out the existing records. Moreover, zero record elimination (compression/Light Optimization) cannot be performed selectively to get rid of those records. You can remove zero records from your template or report through Sheet Options but it could have an impact on other users if the same template is being used.

Approach

SAP BW provides a standard program to generate a program for selective deletion - RSDRD_DELETE_FACTS. We will leverage the same program to make it more easy to use for BPC Models.

BPC Models in essence are real-time InfoCubes and hence this program will treat them in a similar fashion as other regular InfoCubes. Here is how the initial screen of the program looks like:

When program is executed after the data target has been entered and option to generate selection program has been selected, the field "Name of report" is populated by an ID - which is generated program that can be used to perform selective deletion. It can also be transported as well.

Execute this generated program, it will direct you to the selection screen where all the fields are available for selection. You can make selections based on single values, ranges, exclusions and other operators. You can put selections and save as variant to be called in process chain.

We will be creating a custom program - ZBPC_DELETE_FACTS where you can make a selection for Environment and its corresponding model for which selective deletion program is required to be generated. We will create a selection screen for selecting BPC Environment and corresponding models in that Environment.

Once you enter the Environment, you will be required to select Model. The program restricts the list of models based on Environment.

When the program is executed successfully, it will display the name of the generated program.

Use this program to create your selection variant. Execute this generated program using SE38 and you will be presented with the selection screen:

After having selected your appropriate selections, you can save it as variant by clicking on "Save" icon.

There is an option to simulate your deletion process as well. It will not delete any records but will let you know how many records will be deleted. This could act as a preliminary check when setting up this process.

Now you have the program name and the variant and that is all that is needed to execute it via process chain.

Remember to turn the BPC Model to Load Mode before calling the program and turn it back to planning mode after selective deletion program has been executed. Now there are standard process types available in the process chain to do that but there you need to provide technical name.

It would be better to provide Environment and Model ID for selection as we did above for switching between load mode and planning mode. We can create two small programs whereby we can save variant and call that using process chain.

Your process chain will have three programs called in sequence:

- Program with variant to switch BPC Model to Load Mode

- Selective Deletion Program with variant to perform selective deletion of data in BPC Model

- Program with variant to switch BPC Model to Plan Mode

You can configure to trigger this process chain using data manager package too.

Note

Since the program involves deletion of data, please be careful and liaise with your security and compliance team for any concerns. Use your judgement in using it. I cannot be held liable for any issues that it may cause.

13 Comments
Top kudoed authors