Wednesday, February 8, 2017

MDX aggregate measure over specific dimensions

In the cube in our project, there was a need to aggregate a measure only on 3 out of 6 dimensions, so that the aggregation would not filter this measure on any of the excluded 3 dimensions.

After trying Aggregate and Ancesters functions I could finally get correct results with the root function as explained in this blog

https://social.msdn.microsoft.com/Forums/sqlserver/en-US/3b724376-aa6d-4bcc-afcb-a2ac07c94df5/mdx-to-aggregate-measure-over-specific-dimensions?forum=sqlanalysisservices

To sum it up, I created a calculated measure like:

member [measures].[TotalCustYearCat] as (
root([Date].[Calendar Year].currentmember), 
root([Product].[Category].currentmember),
root([Customer]),
[Measures].[Internet Sales Amount]
)

No comments:

c# httpclient The remote certificate is invalid according to the validation procedure: RemoteCertificateNameMismatch

 If we get this error while trying to get http reponse using HttpClient object, it could mean that certificate validation fails for the remo...