Introduction
SAP introduced the MRP live in S/4 HANA to perform the production planning. This tool is similar to classic MRP from business perspective but is completely different from the technical side since it’s leveraging the new capabilities of S/4 HANA like the use of the CDS views or the execution of AMDP method on the database level to select the data. I want to share with you, in this blog, how SAP S/4 HANA is using CDS views to load the transactional data needed for the MRP calculation under MRP live.
As all Functional consultants (I suppose), I have started looking for CDS view to be able to use them or to propose them whenever a custom development is needed (Interfaces, Fiori applications or an ABAP report) since its performance is much more better than selection to the application server and assume like SAP recommends to use the existing objects like methods and function module while building the reports, it could be recommended to use available CDS views when possible. This search brings me to the function module MD_MDPSX_READ_API which is recommended in SAP note 2268085 to be used to extract MD04 records. By diving into the function module, I found AMDP method GET_MRP_ELEMENTS of class CL_PPH_READ_CLASSIC that includes the CDS view used by SAP to select the transaction records.
1- List of CDS views
The DDL SQL view for every transactional object are:
Transactional object | DDL SQL View |
Reservation | v_pph_resb_flex |
v_pph_resb_agg |