Dynamically MDX for PAW view
Posted: Tue Oct 12, 2021 8:10 am
Hello Everyone,
today I have problem with view mdx. I have a 5 Cubes like 001_Cube,002_Cube,003_Cube and every cubes has the same number of dimensions. The differences on structure is between name of first dimension, because the every first dimension has the number prefix like 001_Dim, 002_Dim.
The first view is creating for below statement
SELECT NON EMPTY {[Dim_2].[Dim_2].[Export Date]} ON 0, NON EMPTY {[001_Dim].[001_Dim].[Total]} ON 1 FROM [001_Cube]
Next to I'm using the information about choosing cube on admin Cube and the view mdx looks like:
SELECT {[Meas].[Meas].[Chosen Cube]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube]
The main problem is between connection on this two mdx because I need to change first mdx that when i change chosen cube the view automatically changes the cube and first dim .
I'm trying to connect this statement like this
SELECT NON EMPTY {[Dim_2].[Dim_2].[Export Date]} ON 0, NON EMPTY {[SELECT {[Meas].[Meas].[Chosen Dim]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube].[SELECT {[Meas].[Meas].[Chosen Cube]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube].[Total]} ON 1 FROM SELECT {[Meas].[Meas].[Chosen Cube]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube]
But this statement is uncorrect.
Can you tell me how to connect this two information and create the dynamic view in PAW?
today I have problem with view mdx. I have a 5 Cubes like 001_Cube,002_Cube,003_Cube and every cubes has the same number of dimensions. The differences on structure is between name of first dimension, because the every first dimension has the number prefix like 001_Dim, 002_Dim.
The first view is creating for below statement
SELECT NON EMPTY {[Dim_2].[Dim_2].[Export Date]} ON 0, NON EMPTY {[001_Dim].[001_Dim].[Total]} ON 1 FROM [001_Cube]
Next to I'm using the information about choosing cube on admin Cube and the view mdx looks like:
SELECT {[Meas].[Meas].[Chosen Cube]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube]
The main problem is between connection on this two mdx because I need to change first mdx that when i change chosen cube the view automatically changes the cube and first dim .
I'm trying to connect this statement like this
SELECT NON EMPTY {[Dim_2].[Dim_2].[Export Date]} ON 0, NON EMPTY {[SELECT {[Meas].[Meas].[Chosen Dim]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube].[SELECT {[Meas].[Meas].[Chosen Cube]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube].[Total]} ON 1 FROM SELECT {[Meas].[Meas].[Chosen Cube]} ON 0, {STRTOMEMBER("[}Clients].[" + USERNAME + "]")} ON 1 FROM [Admin_Cube]
But this statement is uncorrect.
Can you tell me how to connect this two information and create the dynamic view in PAW?