Relative Contribution to Total Value (Percentage)
filed in mdx on Jun.24, 2008
There’s a few scenario to calculate a percentage of a measure in OLAP CUBE (Analysis Service 2000). A Percentage is common calculation in MDX , and it can be solved by divide a measure to total value (Grand Total).
Sample 1:Measures.[Value Contribution to Total]:
1 | (Measures.[Value] / (Measures.[Value], Time.[ALL Time], Products.[ALL Products],…) |
Sample 2:Measures.[Value Contribution to Total]:
1 | (Measures.[Value] / (Measures.[Value], Products.[ALL Products],Warehouses.[ALL Warehouses]) |
Sample 3:Measures.[Product Contribution to Total Products]:
1 | (Measures.[Value] , Products.CurrentMember) / (Measures.[Value], Products.[ALL Products]) |
Source:
Leave a Reply