Built in Function $COUNT_PARTS with an example model
Hello Friends,
In this blog, I am going to share an example model on how to use Built in Function $COUNT_PARTS.
I used LAPTOP as class and few characteristics associated with it.
Before getting started, please read below SAP help documentation.
Built-In Function $COUNT_PARTS – Variant Configuration (LO-VC) – SAP Library
Steps to be followed:
1. Create Configurable Materials
i) LAPTOP,
ii) LP_DUMMY (this is dummy material)
2. Create Variant Classes i) LAPTOP, ii) LP_DMY and assign required characteristics.
i) LAPTOP class
ii) DUMMY Class (only with QUANTITY Characteristic to assign the count parts value)
3. Create configuration profile for both materials.
i) LAPTOP material configuration profile.
ii) DUMMY material configuration profile
Check Multi-level BoM explosion for both config. Profiles.
4. Maintain BoM for Material LAPTOP.
At the end of the BoM assign the Dummy material.
5. Write Procedure for the $COUNT_PARTS at configuration profile level of Dummy material.
I used T-code – PMEVC
6. Write Constraint at Main material configuration profile to transfer the value from dummy material to Main material.
OBJECTS: HEAD IS_A (300)LAPTOP,
DUMMY IS_A (300)LP_DMY
RESTRICTIONS:
HEAD.L_QUANTITY = DUMMY.L_QUANTITY
Make sure that classes and dependencies are in release status before simulation.
7. Simulation for LAPTOP
Test the configuration Model by entering the characteristics values.
Now Component Quantity value is empty.
Click on “Result” button highlighted above to simulate the BoM for the given combination.
BoM got exploded.
Click on Characteristics button to check the QUANTITY char value.
Now, QUANTITY char updated with Count of the BoM materials.
In the above example after checking the result,
COUNT_PARTS procedure will check Number of Materials in the resultant BoM and assigns it to dummy material Quantity characteristic.
Constraint at Main material will fetch the value from dummy material qty char and assigns it to Main material Quantity characteristic.
This will be help full in scenarios, where requirement is to count the resultant Bill of materials components.
Dear RaviKumar,
It is appreciable that your post helps us in understanding the practical use of classes, characteristics, configurable materials and BOMs in conjunction with the built-in function in the simplest terms possible.
Regards
Kiran
Thanks 🙂
Dear Ravi,
Your understanding of VC is very deep. Thank you for this wonderful blog with clear examples. Thanks for sharing as well. 🙂
Kind Regards
Atul
Hi Atul,
I am facing difficulty in getting the output as above ,followed all above steps.
Let know insights on this.
Vignesh V