
1. Re: Division & LOD Calculation Problem
Jim Dehner Sep 11, 2019 6:37 AM (in response to Christine Wang)1 of 1 people found this helpfulI opened your workbook and started going through the hierarchy of calculations
you are consistently neglecting to aggregate the measures in your formulas
for example if you write A/B what happens is for every record A is divided by B and when you bring that to the viz it is aggregated with sum  that will total all rhe individulal results at the revord level  (add up all the a/b's together)
the correct way is to write sum(A)/Sum(B) this will add up all the A's and all the B's then divide the total A by the total B
you will need to apply the same logic throughout you book to get the correct results
and remember LOD's are not aggregates and need to aggregate as above
Jim
If this posts assists in resolving the question, please mark it helpful or as the 'correct answer' if it resolves the question. This will help other users find the same answer/resolution. Thank you.

2. Re: Division & LOD Calculation Problem
Zhouyi Zhang Sep 11, 2019 6:56 AM (in response to Christine Wang)Hi, Christine
Not very sure what's your expected result, but please find my attemp attached.
Below is the result
Hope this helps
ZZ

Div LOD cal_v10.5.twbx 57.6 KB


3. Re: Division & LOD Calculation Problem
Christine Wang Sep 11, 2019 9:05 PM (in response to Zhouyi Zhang)Hello ZZ,
Thank you! That is exactly the result I wish to get.
And, wow, so an IF function can go within the SUM aggregation. A new lesson learned. Really appreciate it!
Best regards,
Christine

4. Re: Division & LOD Calculation Problem
Christine Wang Sep 11, 2019 9:10 PM (in response to Jim Dehner)Hello Jim,
Thank you for the clarification! Indeed, I constantly struggle with when and what type of aggregation should be applied. Reading more on this subject does help. Thanks again for your reply and for making it a bit more comprehensible.
Best regards,
Christine

5. Re: Division & LOD Calculation Problem
Jim Dehner Sep 12, 2019 6:57 AM (in response to Christine Wang)glad to be of help  it it really helped you lease mark the response helpful to acknowledge the effort'Jim