mdx

MDX Calculated Measure Count

泄露秘密 提交于 2021-02-07 10:55:47
问题 I'm attempting to add a calculated measure to a simple MDX query. Although I have managed simple calculated measures before I clearly don't understand MDX sufficiently to make this work. Anyway, what I am trying to do is count the number of distinct orders per each of our truck routes. I have tried counting the Order Dimension Keys but all this does is produce the total number of orders in the system rather than the number of orders per route. Can someone help me out? I feel that once I

SSAS MDX Previous Year - Ignore Filter

倖福魔咒の 提交于 2021-01-28 20:19:20
问题 i try to get actual turnover and the turnover of the previous year in the same period. I write this query: with member [Measures].[Turnover PrevYear] as IIF( IsEmpty([Measures].[Turnover Actual] ), NULL, SUM( (ParallelPeriod( [Date].[Year - Quarter - Month - Date].[Year],1,[Date].[Year - Quarter - Month - Date].CurrentMember)) , [Measures].[Turnover Actual] ) ) Select non empty{[Measures].[Turnover Actual],[Measures].[Turnover PrevYear]} on Columns, non empty{[Store].[Store].[Store].members}

How to Overcome MDX Query Error When It Can't Find Specific Entity

≯℡__Kan透↙ 提交于 2021-01-27 18:52:54
问题 When i run MDX query like: select {[Measures].[all_accounts]} ON COLUMNS, {{[Country].[Country].[Country].&[italy]}* {[TD].[TD].[date].&[2016-09-02T03:00:00.000]:[TD].[TD].[date].&[2016-09-02T03:08:00.000]}, {[Country].[Country].[Country].&[Germany]}* {[TD].[TD].[date].&[2016-08-16T04:00:00.000]:[TD].[TD].[date].&[2016-08-16T04:03:00.000]}} ON ROWS FROM [cube] i get an error because 'italy' is not an entity found in Country dimension. and no result is coming back. i want to be able to run the

Difference between tuple and set in mdx

ぃ、小莉子 提交于 2020-12-29 02:59:47
问题 What is the difference between tuple and set in MDX. How we can distinguish both and when we are using them. 回答1: A tuple is a single hierarchy member taken from all the dimensions. Suppose Time.[2nd half] is a tuple of time dimension. At the same way we can have multiple tuples and we represent them in '(',')' brackets. Eg: (Time.[2nd half], Color.Dark.Red). This is nothing but the mathematical intersection of nodes. we can represent the nodes in maths as (2,1) in the same way above

How to implement “greater than” based on dimension value in MDX

亡梦爱人 提交于 2020-12-16 02:24:16
问题 I would like to query the total sales of each country with the GDP growth rate of more than 3. So far, I can display the sales information of each country like such: SELECT {[Measures].[Sales]} ON 0, {[Dim Company Info].[LOC].ALLMEMBERS} ON 1 FROM [Database] But then I am still blank on how to query all GDP growth rate of more than 3. I have searched SO and found filter to be the answer, however, I do not know where to include it in my code above. How do I go about this? Edit: I have tried

How to implement “greater than” based on dimension value in MDX

我是研究僧i 提交于 2020-12-16 02:24:10
问题 I would like to query the total sales of each country with the GDP growth rate of more than 3. So far, I can display the sales information of each country like such: SELECT {[Measures].[Sales]} ON 0, {[Dim Company Info].[LOC].ALLMEMBERS} ON 1 FROM [Database] But then I am still blank on how to query all GDP growth rate of more than 3. I have searched SO and found filter to be the answer, however, I do not know where to include it in my code above. How do I go about this? Edit: I have tried

custom count measure runs forever MDX

元气小坏坏 提交于 2020-06-17 09:07:12
问题 So this question goes off the one here I've been trying to do a similar count measure and I did the suggested solution but it's still running.... and it's been more than 30 minutes with no results, while without that it runs in under a minute. So am I missing something? Any guidance would help. Here is my query: WITH MEMBER [Measures].[IteractionCount] AS NONEMPTY ( FILTER ( ([DimInteraction].[InteractionId].[ALL].Children, [Measures].[Impression Count]), [DimInteraction].[Interaction State].