Inputs for CS_BOM_EXPL_MAT_V2 – BOM explosion report – CS11
As a PP Functional consultant you may face some specific requirments from the customer. One of which may like below. i.e
The Client was asking a report to display the list of components from header level to the lowest level and to see the stock quantity of each materials at each storage location. Its more over similar to the standard report CS11 – BOM explosion level by level, which we are using.
You may use the tables MAST, STKO, STPO, MARD tables to get the BOM components from header to lower. But you may need to run the loops again and again to get the whole list.
Instead we can go with the function module CS_BOM_EXPL_MAT_V2 which will fetch the details of the BOM components from Header to lower level in a single run.
You may find the inputs of this FM if you have ABAP knowledge. But if you are a functional cousultant without ABAP knowledge it may be difficult to get the inputs for this FM.
We faced such kind of issue and we have searched the input for this FM in internet. But we got the details in technical point of view. But from functional point of view we did not find any details.
With help of technical, we figured out to get the inputs for these FM.
Since I am writing this and it will help you to get the inputs for the bapi CS_BOM_EXPL_MAT_V2.
- Go to SE37 tcode
- Give the Function module CS_BOM_EXPL_MAT_V2
- Click execute
- Give the input parameters as below to get the output.
CAPID is the Bill of Materials Application and as standard it PP01
MEHRS if Multilevel BOM is needed then this field is to be X
MATNRV is the material for which we need to get the component explosion.
To get the report for multiple materials do below things.
First get the list of materials by using the material type in MARA table and pass it in this FM using a loop (feasible via ABAP) to get the list of components for multiple materials.
CAPID = PP01 - (BOM application) DATUV = sy-datum (Explosion Date) EHNDL = 1 (Default) EMENG = 100 (Required Quantity as like in CS11) MKTLS = X (Default) MEHRS = X (Default) MTNRV = MANTR (Material for which you need the output) STLAL = 1 (Default) STLAN = 1 (Default) STPST = 0 (Default) SVWVO = X (Default) WERKS = 2000 (Plant) VRSVO = X (Default)
Click execute to get the values in Result – STB table.
We can get the list of materials by using the
Keep the remaining values in the Function module empty to get the output.
I hope this will help you on developing any custom report for exploding BOM details.
Would like you guys to see more relevent things using the link: https://blogs.sap.com/tags/9aaa6d7b-e017-4ddc-805d-9bbd02a6c46d/),
We would very much appreciate your comments and suggestions below.
Gracias, muy buena explicación, es justo lo que buscaba.