Quantcast
Channel: SQL Server Analysis Services Forum
Viewing all articles
Browse latest Browse all 2472

How to calculate percentage in MDX

$
0
0

I am new to MDX, I have created a calculated member to display the percentage but the values seems to me wrong and the 'SUM Of All TransactionAmount' just doesn't work

(TransactionAmount / Sum Of All TransactionAmount) * 100

is the formula and I have attached the screenshot      

            TransactionAmount    Percentage
UK       1064106239.55        10000.00%
US       51015003.34            10000.00%
Total    1115121242.89        10000.00%


CREATE MEMBER CURRENTCUBE.[Measures].Percentage
 AS
(SUM([Measures].[TransactionAmount])  / [Measures].[TransactionAmount] )  * 100 ,
FORMAT_STRING = "Percent",
VISIBLE = 1  ; 



Viewing all articles
Browse latest Browse all 2472

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>