Forum Discussion
Weighted Average sub-total not correct despite correct calculation?
Hi, shanestocks
According to your description, you want to get a weighted average price of a "P CODE",but the difficulty is that it's hard to understand how your requirement is realized, you can describe your requirement logically and completely (how the number 5.05368 is obtained), post the related MEASUREMENT (([REQ_COST_ OF_ order],[used (KG)).
Best Regards,
Yang
Community Support Team
- shanestocks2 years ago
Helper I
Hi Yang, the measure is as follows:
=DIVIDE([req_cost_of_order],[used (KG)])
"req_cost_of_order" is a calculated column which multiplies qty_used * meat_price
"used (KG)" is a SUM of the qty_used column.
I also have two other columns that seperate the P CODE and the M CODE with the above table being a key that merges them both together.
I am thinking that at the P CODE level it should be the weighted average, and at the M CODE level it should simply be the meat_price?