Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Sum(Descendants) in MDX Part II

Dear

sum({<#Equipment = {">0"}>}SalesAmount) / sum(#Equipement)

Sum(if(#Equipment >0, SalesAmount,0)) / Sum(#Equipment)

Both of them, give me the same result but it is not what I want. This is becasue there is two records of customer 1004.

In SQL Analysis Services, I can get the answer by using this MDX.

sum(Descendants([Customer].CurrentMember,[Customer].Customer),

(iif ([Measures].[#Equipment)] > 0, [Measures].[SalesAmount] / , 0))) / [Measures].[#Equipment]

Please advise.

Best Regards,

Anote

1 Solution

Accepted Solutions
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

   Please refer to the post.

   http://community.qlik.com/message/127972#127972

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!

View solution in original post

1 Reply
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

   Please refer to the post.

   http://community.qlik.com/message/127972#127972

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!