SAP S/4HANA Cloud, SAP S/4HANA Cloud for Finance

How to Get Manufacturing Orders Check Whether Header Materials Have Released Standard Costs

Business background

A manufacturing company may introduce new products periodically, with production department responsible for the maintenance of product master data, BOM and routing , and accounting department responsible for standard costing runs, situation could arise when manufacturing orders are created without standard cost estimate runs for the header materials. Standard system behavior allows the transactions go all the way as long as there are standard price values in the product master data; however, the initial input values of standard costs may not be correct, and without released standard cost estimates, the products will not have standard cost component splits, nor target costs and will cause issues with actual costing runs. These kind of issues can be spotted and corrected during month end closing, but would it be ideal if manufacturing orders could raise an error message indicating the header material has no standard cost estimates and stop the issue at its source?

Possible solution

Two things need to come together,

  1. There needs to be a BAdI (Business Add-In) enhancement from Fiori app Custom Logic available to be called upon in manufacturing order creation
  2. There needs to be a data source to lookup the product and plant combination to see whether a released standard cost estimate exists for thereof product

In SAP S/4HANA Cloud, it is only possible to do so recently after 2108 release. In 2105 release, parallel accounting features see some architecture changes, one of which is in relation to standard cost estimates being stored in table ACDOCP (for materials have BOM and routing), instead of table KEKO and table CKIS, because latter tables have no ledger fields. The CDS view sits on top of ACDOCP is I_FinancialPlanningEntryItem, and it is a released CDS View.

In 2108 release, a new BAdI has become available, it’s called ‘Manufacturing Order Check before Save’ under ‘Order Master Data’ business context. The BAdI functions as the name suggest, it checks certain conditions, and raise error messages accordingly.

First, let’s have a look at one specific example and see how released standard costs are stored in ACDOCP in comparison with Fiori app Display Material Cost Estimates(CK13N). Standard costing entries are populated in ACDOCP with planning category PLANORD02.Amounts are grouped by G/L accounts, this is consistent with amounts grouped by cost elements in CK13N. One noticeable difference is the additional row from ACDOCP: a negative amount, with 55100000 in the screenshot. This is the account gets posted when performing manufacturing order settlements (transaction key GBB, grouping AUA). This ‘negative’ amount is basically the total standard cost, adding up the positive amounts (the component amounts), this product will have a zero balance.

As in the cloud system, users do not have direct access to tables. Instead, the released CDS view ‘I_FinancialPlanningEntryItem’ can be used to look up standard costs.

Once the BAdI implementation is released, if header material’s standard cost is not found, an error message can be issued preventing the manufacturing order from saving.

While you are at this, perhaps as a spinoff exercise, you may want to put more thoughts in creating a custom query and make a polished multidimensional report showing product standard costs with component splits

Create a custom CDS view

Create a query based on the CDS view

Preview the query

Important notes:

  • The article is from an application consultant point of view; therefore, the coding and the custom report only serve as demonstrative purpose, not recommended for copying, and may be somewhat crude from the eyes of technical experts.
  • This is not an SAP official KBA. This article merely takes advantage of the newly released BAdI and the fact that standard costs are stored in table ACDOCP, and there happens to be a released CDS view. There is no guarantee this approach can work for all business scenarios such as sales order costing, thorough testing is recommended before productive use.
  • All the demo data depicted in screenshots are generic names without any reference to real business data

Leave a Reply

Your email address will not be published. Required fields are marked *