Financial Management Blogs by SAP
Get financial management insights from blog posts by SAP experts. Find and share tips on how to increase efficiency, reduce risk, and optimize working capital.
cancel
Showing results for 
Search instead for 
Did you mean: 
ARRamos
Advisor
Advisor

Ever heard or experienced splitting the bill after dining out with colleagues and friends? It might be just simple mathematics at first until there are portions of the bill that were not distributed nor allocated. Then how should this bill be handled?


Come to think of it, “allocation with unassigned items” can happen to anyone daily and we just don’t realize it. Maybe you are already imagining now instances where you split restaurant bills with your friends, but the focus of this blog post is much deeper than that.


In this blog post, we will be using an Allocation function with two Model Tables as the Sender and Receiver.



The following are the kind of questions that this blog post aims to answer:




  • Will it run smoothly and present an expected result?

  • What if some amount from the Sender becomes unassigned or unallocated, how do we deal with that?

  • In addition, is it possible to use another function in consuming an Allocation function?



Before we proceed, let us first make sure to:

  1. Maintain the correct settings in the Allocation function – Function Attributes



Event Handling = set to ‘Management’

For allocation with unassigned item scenarios, this setting is a must. This will enable the creation of a business event in the My Events application - where further processing of such events will be handled.

Processing Type = set to ‘Executable’

One of our goals in this blog post is to have another function to further display the result of our allocation, so these 2 functions (Allocation + Other Function) need not be executed separately and can be done in a single run. Having this setting, PaPM enables the simultaneous processing of this chain of 2 functions by running the Other Function which will consequently trigger the execution of the Allocation function.

  1. Maintain the granularity of fields (for unassigned items) in the Calculation Unit – Business Event Fields.



This will enable business event error handling to be done at a common level. And with that we mean having to deal only with the Characteristic fields where usually, differences between the Sender and Receiver data are likely to cause these unassigned items.

Now let’s get started.

Let’s say we already have an Allocation function and it already has its Sender and Receiver Model Table.


Once we have another function, such as View, having the Allocation function as its Input, we run the View function, it will automatically be projecting the Result same as with the Allocation function. Unless there are some configurations done in View such as removal of a Field and so on.


Upon View execution, we notice that there are some data records from the Sender Model table which were not allocated, what do we do?


Below is an example View result with unassigned items.


View Result





































































Product Customer Amount Coverage Distribution Rate
238 AA 60 6989 20
238 AA 240 6990 80
224 DD 120 6981 60
224 DD 80 6982 40
238 AA 80 6989 20
238 AA 320 6990 80
224 DD 240 6981 60
224 DD 160 6982 40

With an error message "Processing Message Unassigned Items" for Volume=1000 and Quantity=1"



Since we have an Unassigned Item, we can process it through Business Event Management (BEM). Please follow the steps below:


a. Go to "Start My Events" by following the steps below:


*SAP Menu > Profitability and Performance Management > Execution > Start My Events



b) Locate the Unassigned Item from your Allocation function, from the Function Hierarchy.


c) Click on "Edit" from the Function Details.


d) Select "Adjustment" from the Event Type and make the necessary adjustments on the Assignments field. Please see descriptions below about the different Event types.


e) Click on "Run" then choose "Partial Restart” then Save.



Note: In case Business Event Fields were not registered, all individual fields will be displayed for event handling


After processing the unassigned items, go to the Allocation function, then choose “Show” and you’ll see that the Unassigned Item has now been allocated.






























































































Product (ZE_PROD) Channel (ZE_CHNL) Customer (ZE_CUST) Amount (ZE_AMT) Coverage (ZE_CVRG) Distribution Rate (ZE_DRBRT)
238 92H2 AA 60.00 6989 20
238 92H2 AA 240.00 6990 80
224 92H2 DD 120.00 6981 60
224 92H2 DD 80.00 6982 40
238 92H2 AA 80.00 6989 20
238 92H2 AA 320.00 6990 80
224 92H2 DD 240.00 6981 60
224 92H2 DD 160.00 6982 40
238 CXH0 DD 450.00 6986 45
238 CXH0 DD 550.00 6985 55

At this point, after showing the data from the Allocation function, we will not Run Allocation or View function again. Running those two functions again will cause the Allocation function to be retriggered and will cause Unassigned Items again. How will we run the View function without retriggering the Allocation and having Unassigned Items again? This is where the Process Activity will take place.


Process templates are used to specify the set of functions that are relevant for execution. A process template is structured by one or many activities which have to be executed to finish the process. In the next steps, we will be using the Allocation function as an Activity function for the Process Template.


To create a Process Template, follow the steps below:


1.) Under Calculation Unit, go to Process Tab and from there create one Process Template.


2.) Add an activity and assign your Allocation function on Function/URL tab.


3.) Activate.



We are done creating our Process Activity, now we can execute our View function.


View Result after running with Process Activity






























































































Product Channel Customer Amount Coverage Distribution Rate
238 92H2 AA 60 6989 20
238 92H2 AA 240 6990 80
224 92H2 DD 120 6981 60
224 92H2 DD 80 6982 40
238 92H2 AA 80 6989 20
238 92H2 AA 320 6990 80
224 92H2 DD 240 6981 60
224 92H2 DD 160 6982 40
238 CXH0 DD 450 6986 45
238 CXH0 DD 550 6985 55

If you look at the above result, you’ll be able to see that the previously unassigned items have now been allocated.


By Executing the View function, with the Allocation as its Input function, we are consuming the data, which we have already corrected the unassigned items through BEM. That is because we used a Process Template with the Allocation function as an Activity.


You can look at it this way. We initially run the View function, we got unassigned items from the Allocation, which was its input, then we process it through BEM. Without Process Activity, if we run the View function again, it will retrigger the Allocation function and unassigned items will be shown again. However, executing the View function with a Process Activity, it will just consume the corrected buffered data of the Allocation function and not retrigger it.


The process flow of what we have discussed can be seen below:



I trust that reading this blog post helped you understand how another function can consume an Allocation function and also how to deal with unassigned items from an Allocation function. Moving forward, I truly believe that you'll be able to apply this hint on some related scenarios in the future and be confident enough in handling them.


Do you have other items to add in relation to this blog post that I may have not mentioned? Please feel free to post a comment below! 😊


For other SAP Profitability and Performance Management related inquiries, you can post your questions through https://answers.sap.com/questions/ask.html and use primary tag: SAP Profitability and Performance Management.


You can also read other SAP Profitability and Performance Management posts via https://community.sap.com/topics/profitability-and-performance-management.


Thank you so much for reading and watch out for other interesting SAP Profitability and Performance Management related topics on the next blog posts.