S4 HANA Retraction of Plan Data From BPC To SAP IBP
S4 HANA Retraction of Plan Data From BPC To SAP IBP
S4 HANA Retraction of Plan Data From BPC To SAP IBP
Appli es t o:
SAP BPC for S/4HANA
Summary
SAP customers who use a standalone SAP BPC system for financial planni ng often want to retract the plan
data to the operational ERP system to allow for Plan/Actual comparisons. The Interface customers use for
this purpose is a BAPI that stores that plan directly in the FI/CO tables.
S/4HANA
with its richfeatures a new planning
set of planning functionsmechanism called
can be used SAP
as an BPC for toS/4HANA.
alternative This
the classic planning environment
GUI-based planning
This document shows how to retract the plan data from a standalone SAP BPC system into SAP BPC for
S/4HANA in order to allow Plan/Actual comparisons directly in S/4HANA.
It also goes through an exercise of enhancing the delivered content with an additional reporting dimension
for the Trading Partner.
Autho r:
Philip Pre issi ng
Company:
SAP Deutschland SE & Co.KG
Author Bi o
Philip Preissing is a Senior EPM Consultant in SAP Services. He works closely with the Product
Management of S/4HANA, particularly in the area of SAP BPC for S/4HANA.
1
Table of Contents
Background Information ........................... .............. .............. .............. .............. .............. .............. .............. ...............3..
Step 1: S tandalone SAP B PC Enviro nment ................................................................................................................................6
Step 2: Crea te SAP BPC Retraction BAdI ...................................................................................................................................7
Step 3: Load data into SAP BPC for S/4H ANA ........................................................................................................................10
Step 4: Plan/Actual comparison via Analysis for Office .....................................................................................................19
Step 5 : Autom ation ..........................................................................................................................................................................22
Step 6 (optional): Enhance the delivered Infoprovider with additional characteristics ........................................... 23
2
Bus iness Sce nario
SAP customers that implemented planning solutions in a standalone SAP BPC environment often wish to retract
plan data back into ERP to allow Plan/Actual comparisons directly in the ERP system.
Technically, this is usually implemented via a Retraction BAdI calling a BAPI to insert the plan figures into the
1
corresponding ERP tables . S/4HANA features a new planning mechanism called SAP BPC for S/4HANA. This
planning environment with its rich set of planning functions can be used as an alternative to the classic GUI-based
planning transactions.
Using SAP BPC for S/4HANA content to facilitate Plan/Actual comparisons now requires to retract the plan data
into the data model of SAP BPC for S/4HANA. This how-to document describes the necessary steps for
implementing this retraction.
Depending on the exact scenario it will most likely require adapting to the source data model and source system.
The how to assumes that the reader is familiar with basic BW modeling.
1
cf. http://www.sdn .sap.com/irj/scn /go/portal/pr troot/docs/libra ry/uuid/c029accf ,6d95,2d10,79aa,
cc291180bf73?QuickLink=in dex&overridelayout =true&59180354379512
3
BW
Multiprovider /ERP/SFIN_M01
Plan Data
On the highest level are the Analysis Office Workbooks, with which the end user can enter planned figures.
The figures entered in this way are persisted in InfoCube /ERP/SFIN_R01.
InfoProvider /ERP/SFIN_V01 is used to read the actual values from the previous year and compare the
planned values of the current year in t he Workbooks.
Apart from the delivered workbooks, SAP BPC for S/4HANA also contains 24 BEx queries that can be used
for Plan/Actual comparisons:
Technical Name Query
/ERP/SFIN_M01_Q2001 Cost Centers , Plan/Actual
/ERP/SFIN_M01_Q2101 Internal Orders , Plan/Actual
/ERP/SFIN_M01_Q2201 Projects , Plan/Actual
/ERP/SFIN_M01_Q2501 Market Segments , Plan/Actual
/ERP/SFIN_M01_Q2701 Profit Centers , Plan/Actual
/ERP/SFIN_M01_Q2901 P&L , Plan/Actual
/ERP/SFIN_M01_Q2002 Cost Centers , Plan/Actual YTD
/ERP/SFIN_M01_Q2102 Internal Orders , Plan/Actual YTD
/ERP/SFIN_M01_Q2202 Projects , Plan/Actual YTD
/ERP/SFIN_M01_Q2502 Market Segments , Plan/Actual YTD
/ERP/SFIN_M01_Q2702 Profit Centers , Plan/Actual YTD
/ERP/SFIN_M01_Q2902 P&L , Plan/Actual YTD
4
/ERP/SFIN_M01_2003 Cost Centers , Plan/Actual with Currency
/ERP/SFIN_M01_2103 Translation
/ERP/SFIN_M01_2203 Internal Orders , Plan/Actual with Currency
/ERP/SFIN_M01_2503 Translation
/ERP/SFIN_M01_2703 Projects , Plan/Actual with Currency
/ERP/SFIN_M01_2903 Translation
Market Segments , Plan/Actual with Currency
Translation
Profit Centers , Plan/Actual with Currency
Translation
P&L , Plan/Actual with Currency Translation
/ERP/SFIN_V01_2001 Cost Centers , Actuals
/ERP/SFIN_V01_2101 Internal Orders , Actuals
/ERP/SFIN_V01_2201 Projects , Actuals
/ERP/SFIN_V01_2501 Market Segments , Actuals
/ERP/SFIN_V01_2701 Profit Centers , Actuals
/ERP/SFIN_V01_2901 P&L , Actuals
5
Cost Center Plan/Actual Query:
e.g. /ERP/SFIN_M01_Q2001
/ERP/SFIN_M01
Multiprovider
/ERP/SFIN_R01
Infoprovider
/ERP/SFIN_V01
Virtual Provid er
Retraction
BAdI
Generic
PSA
Data Source SAP BPC Model
Standard
Retraction table
DSO
ERP Actuals
SAP BPC content
BW Modeling required Delivered
Simple Finance System SAP BPC for S/4HANA content
In order to move data from the standalone SAP BPC system, we first extract it from the SAP BPC Model into a flat table using
the SAP BPC Retraction BAdI. We then create a generic data source on top of the table to make it accessible from the SAP
BPC for S/4HANA System.
In the S/4HANA system we replicate the Data Source and create a field structure. Then we first load it into a Standard DSO in
order to calculate the Delta, before we move it into the Planning Infoprovider of SAP BPC for S/4HANA.
The delivered Multiprovider /ERP/SFIN_M01 combines our retracted plan with real,time actuals from the underlying ERP
system. The data can be analyzed with the delivered BEx queries in Analysis for Office and other frontend tools supporting BEx
queries.
6
Using a simple Input Schedule, we can enter some test data:
Create a field structure based on the source data model. In our example, we use:
Note: In case you are using multiple clients in the target ERP system (e.g. for IST, UAT), please
include an additional field into this structure to store the target client.
7
In the Technical Setting, maintain data class and size category:
Then, create a new Retraction BAdI that can be used from SAP BPC. Use SE19 to create
it for Enhancement Spot UJD_RETRACT:
8
Set the filter value:
Create the BAdI Implementation as a simple logic to write the passed data to the earlier created
retraction table.
For details on the retraction BAdI and sample code, please refer to
http://www.sdn.sa p.com/irj/scn /go/portal/prtro ot/docs/librar y/uuid/c029accf,6 d95,2d10,79aa,
cc291180bf73?QuickLink=index&overridelayout=true&59180354379512
9
Create a new empty transformation file to be used for the retraction:
Run the package to make sure it is working. In the prompts, select SIGNEDDATA as the measure,
the new empty transformation file and the chosen BAdI filter.
Create the SAP BPC system as a source system in the S/4HANA system
Replicate the data source to the S/4HANA system and check in Preview that data can be
retrieved:
10
Right,click on the Datasource and create a new Infopackage:
Execute the Infopackage and check that data can be loaded into the PSA:
11
Create a new Standard DSO that we can use to store the data:
Select the Infocube (/ERP/SFIN_R01 in Infoarea /ERP/SFIN) as a template for the new DSO:
12
Select the following key and data fields:
Note: In case you are using multiple clients in the target ERP system (e.g. for IST, UAT), please
include the Infoobject 0MANDT into this DSO t o store the target client.
13
Right,click on the DSO and create a new Transformation:
14
Create the following Transformation :
The Fiscal Year Variant can be read as an Attribute of the Company Code with the following rule:
15
Create a new DTP to load data from the PSA to the DSO:
Run the DTP to make sure that data is arriving in the DSO:
Now the data in the DSO needs to be activated by right,clicking on the DSO and choosing „Activate
Data“:
16
After activation, the data is available in the DSO and can be checked via Right click and Display
Data:
Now, find the,Planning Infoprovider with the technical name /ERP/SFIN_R01 and create a new
transformation to load data from our DSO:
The profit center (/ERP/PROFTCTR) can be read as master data from the Controlling area
17
(/ERP/CO_AREA) and the cost center (/ERP/COSTCNTR).
Constantly define the Debit Credit Indicator (/ERP/DCINDCO) as ‘D’.
The client needs to be defined as a formula:
Note: In case you are using multiple clients in the target ERP system (e.g. for IST, UAT), please fill
the client based on the additional field in the DSO.
Create a DTP for the transformation and run it to make su re the data is moved correctly to the
Infoprovider. Note that you need to switch the Real,time load behavior (Right,click on Infocube !
„Planning,speci fic properties“) to „Load mode“ first. Use „Display Data“ to verify the result:
18
Step 4: Plan/Actua l comparison via Analysis for Office
Open Analysis for Microsoft Excel. Choose the Analysis ribbon and click on “Insert”. Choose “Select
Data Source…”:
19
Skip the first window:
20
Search for “/ERP/SFIN_M01_Q2001” (or any other query listed in the Introduction) and open the
query:
Choose the right Fiscal Year, Version, Company Code and Cost Center and press OK:
21
The Plan/Actual comparison shows the plan figures we loaded through BW:
Apart from Analysis for Office, the BEx queries can also be consumed in other applications, such as the BEx
Analyzer or the EPM AddIn.
Step 5: Automation
To automate the loading process in the S/4HANA system, a process chain can be created. Note that the
target Infocube needs to be switched to “Load mode” before the final DTP can be run. Afterwards, we
switch it back to “Plan mode”.
22
To automatically start the S/4HANA process chain right after the retraction program, you can use an ABAP
call to Function Module BICS_CONS_EXEC_PROCESS_CHAIN via RFC in the S/4HANA system.
Note: In case you are using multiple clients in the target ERP system (e.g. for IST, UAT), the function module
needs to be run in the BW client.
This way, you could for example call it at end of the Retraction BAdI to allow for a seamless user experience.
Our source data contained three fields for the Trading Partner, the Trading Partner Business Area and
Trading Partner Segment. As of the current release, SAP BPC for S/4HANA does not cater for these fields,
but we can enhance the standard content to include these fields relatively easy.
For this, we will go through the following steps:
1. Create the necessary Infoobjects
2. Include the new fields in our DSO
3. Copy and adjust the delivered Planning Infoprovider, Virtual Provider and Multiprovider to i nclude the
Trading Partner information
4. Copy and adjust the BEx query to include the Trading Partner information
Note that we while in t his how to we create copies of all delivered objects before changing them, in real
customer scenarios it can also be opted for enhancing the delivered objects directly thereby saving some
implementation effort . In case of new shipments from SAP, customers can then decide whether they want to
overwrite the content with new version, stay with their current one, or merge them.
Create new Infoobjects for Trading Partner Business Area and Segment. Choose the respective
reference characteristics (/ERP/BUSAREA and /ERP/SEGMENT):
23
Modify the DSO we created earlier. Include the Trading Partner (/ERP/TDP) and the two
characteristic s we included earlier for Trading Partner Business Area and Segment.
24
Note that you might need to delete the data from the DSO to be able to change the structure.
Enhance the underlying transformation to move the new fields from the PSA to the DSO:
Activate the transaction and reload the data (DTP and DSO activation). Make sure the data arrives in
the DSO:
25
Now we have to copy the delivered Infocube, the Virtual Provider and the Multiprovider so that we
can enhance it with the Trading partner information. We start with the Infocube /ERP/SFIN_R01:
26
After the copy, we create a new dimension and add the Trading Partner characteristics :
27
28
Of course, we also need to recreate the transformation and DTP from our DSO to the new Infocube.
The steps and mapping are similar as described in the previous section:
We then continue with copying the virtual provider /ERP/SFIN_V01: We also copy it first to a new
name and then enhance it with the new characteristics:
29
30
(Note that the delivered Virtual Provider already contained the Trading Partner (/ERP/TDP) in the
Organization Units dimension. For the sake of clarity, we move it to the new dimension)
Once we have added the characteristics, we need to assign them to the respective HANA view fie lds
(SBUSA for the Business Area and PSEGMENT for the Segment):
31
Then activate the virtual provider.
32
Then we can copy the multiprovider /ERP/SFIN_M01:
33
Add the Trading Partner and identify the charact eristics and keyfigures for the mapping:
Now we just have to adjust the BEx queries to include the trading partner information. In this
example, we use the Cost Center Plan/Actual query (/ERP/SFIN_M01_Q2001).
We start by opening the query in the query designer:
34
First, we save a copy of the query on our namespace so that we can adjust it afterwards:
Even though we copied the query now, it will still use the pre,delivered Infopro vider. Since we would
like to use our enhanced Infoprovider now, we need to copy the query using transaction RS ZC:
35
36
Once the query is copied successfully, we open it in the Query Designer and add the Trading Partner
as free characteristi cs:
37
Additionally, we need to modify the calculated keyfigures for Actual and Plan Amount to include our
new Infoprovider names:
38
After saving the query, we can open it in Analysis for Office and analyze by the Trading Partner
information:
As a last step, the process chain should be adapted to include the new DTPs and Infoprovider:
39
© 2015 SAP SE SE or an SAP SE affiliate company. All rights reserved.
No part of this publication may be reproduced or transmitted in any
form or for any purpose without the express permission of SAP SE.
The information contained herein may be changed without prior notice.
Some software products marketed by SAP SE and its distributors contain proprietary software components
of other software vendors. National product specifications may vary.
These materials are provided by SAP SE and its affiliated companies (“SAP SE Group”) for informational
purposes only, without representation or warranty of any kind, and SAP SE Group shall not be liable for
errors or omissions with respect to the materials. The only warranties for SAP SE Group products and
services are those that are set forth in the express warranty statements accompanying such products and
40