Questions tagged [mdx-query]

A sample MDX query looks like below.

[ WITH <SELECT WITH clause> [ , <SELECT WITH clause> ... ] ]   
SELECT [ * | ( <SELECT query axis clause>   
    [ , <SELECT query axis clause> ... ] ) ]  
FROM <SELECT subcube clause>   
[ <SELECT slicer axis clause> ]  
[ <SELECT cell property list clause> ]  
140 questions
1
vote
0 answers

MDX - sum on related stores

help with MDX query please i need to calculated stock pcs for current member as sum of SAME region and only for distribution centers for example first row Object = 'WH_1' Region = 'A' i need to get sum of all ObjectType = 'Distibution Center' for…
Antonio
  • 51
  • 6
1
vote
1 answer

trouble with dynamic year filter in MDX

I have the following query that I use in Azure data factory(this is on the source of a copy action): SELECT { [Measures].[0INV_QTY], [Measures].[0NET_VAL_S] } ON COLUMNS, NON EMPTY { [0CUST_SALES].[LEVEL01].MEMBERS * …
1548346
  • 13
  • 3
1
vote
0 answers

Converting MDX query into SSAS cube expression [Calculations]

How can I go around to amending this MDX query WITH MEMBER [Measures].[PanelSoldMonthsPre] AS ' [In Charge Date].[In Charge Date Days in Month].CURRENTMEMBER.membervalue' MEMBER [Measures].PanelSoldMonths AS [Measures].[Panel Sold Days] /…
Shoaib Maroof
  • 369
  • 1
  • 3
  • 13
1
vote
1 answer

How to resolve "Type Mismatch error" in MDX query

I am struggling with the Type Mismatch error when I query the cube in SSAS. The MDX query is shown below: WITH MEMBER [MEASURES].[TopNFilter] AS IIF ( Count((EXISTING…
Mike Eale
  • 101
  • 1
  • 9
1
vote
1 answer

MDX - Top N elements of every subgroup

Let's assume I have a cube with a sales fact table and 3 dimensions: Time (with hierarchy year-month-day), Geography (with hierarchy continent-country-region) and Product with some characteristics about the product sold, let's take the brand for…
gabriele
  • 35
  • 5
1
vote
1 answer

Missing rank values in MDX when ranking on calculated measures with division

We are trying to rank measures using the RANK() function in our Report Builder dataset, but when the calculated measure being ranked has division in it, it randomly skips values. This is not related to the measure being equal in value then going to…
1
vote
1 answer

MDX Query : Add filters in mdx query

i am new to writing.mdx queries. Trying to add below conditions Need help in pop2019 larger than 5000 GDPgrowth more than 1 Query for sales of each country: SELECT {[Measures].[Sales]} ON 0, {[Dim Company Info].[LOC].ALLMEMBERS} ON 1 FROM…
pythonlearner
  • 85
  • 2
  • 10
1
vote
1 answer

Replace null values with '0' without changing the name of measures

If i rename my measures and use COALESCEEMPTY this works perfectly but i need to maintain the real name of the measures. Does anybody know how to replace null values with 0 without having to rename the measures. WITH MEMBER [Measures].[col_] AS…
E.Lahu
  • 399
  • 3
  • 15
1
vote
2 answers

MDX query in SSAS calculated member

I tried the MDX Query in SQL correctly But I will insert that query in the VisualStudio(SSAS) in the Calculated Members section, but the process time will be faulty Select [Measures].[Fact Student Status Count]on columns From [Cube_REG_Amozesh…
Atarodi
  • 21
  • 4
1
vote
1 answer

MDX sort order in Crossjoin

I want to show a list of callers we have missed calls from within a daterange. I want te result to be ordered by date. But I can't figure out how to do this. My MDX statement: With Member [Measures].[Gemist] AS sum( …
Niels
  • 131
  • 5
1
vote
1 answer

SSAS MDX Previous Year - Ignore Filter

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( …
Alexo
  • 131
  • 4
  • 15
1
vote
1 answer

SSAS MDX Median with time series

I am trying to calculate a median on timeseries monitoring data. The OLAP cube has a date dimension (lowest level is date) and a seperate time dimension. (lowest level is minute) I've found that it calculates correctly for a given day, but it rolls…
Sir Swears-a-lot
  • 402
  • 7
  • 20
1
vote
1 answer

MDX - Grand total missing when filtering

I've been working on an ExcelDNA C# xll that allows users to enter simple words (under guidance) and I construct the elaborate MDX for them to query against a remote ActivePivot cube. During testing I've ntoticed that when filtering, the grand total…
TilleyTech
  • 441
  • 5
  • 13
1
vote
1 answer

Is there a way to convert this MDX syntax to DAX?

I'm changing a legacy multidimensional analysis services to tabular and "Converting" the MDX measures to DAX. (I don't have much knowledge using MDX) I found the script below and i'm not sure what it is doing. ([Origin].[Origin].&[BUDGET…
1
vote
0 answers

How to filter a date range in a cubeset function?

I want to implement a filter in a cubeset function to get the values only for a limited time period, e.g. 2 weeks. However, I struggle with the syntax of the filter function. Getting the values in a cubevalue function works for the selected time…
1 2
3
9 10