MDX Parameter Query with Parameter
Hello,
I need to implement cascading parameters in my report. If two parameters are in the same dimension, this works fine.
But I have two parameters in different dimensions:
Year1 = Year (Dimension Time1)
Year2 = Year (Dimension Time2)
When the user selects Year1 = 2012, parameter Year2 should also switch to 2012.
I added a FILTER function to the MDX query of parameter Year2 generated by SSRS, but it still does not work.
WITH
MEMBER [Measures].[ParameterCaption] AS [Time2].[Year].CURRENTMEMBER.MEMBER_CAPTION
MEMBER [Measures].[ParameterValue] AS [Time2].[Year].CURRENTMEMBER.UNIQUENAME
MEMBER [Measures].[ParameterLevel] AS [Time2].[Year].CURRENTMEMBER.LEVEL.ORDINAL
SELECT {[Measures].[ParameterCaption], [Measures].[ParameterValue], [Measures].[ParameterLevel]}
ON COLUMNS ,
FILTER([Time2].[Year].Members, [Measures].[ParameterCaption] = STRTOMEMBER(@Time1Year, CONSTRAINED)
) ON ROWS
FROM ( SELECT ( STRTOSET(@Time1Year, CONSTRAINED) ) ON COLUMNS FROM [MyCube])
How can I accomplish this?
Thanks
June 8th, 2012 6:05am
Well in your case the best possibility would be to use the Design Mode for Analysis Services MDX Queries. Add the filters on the filters section and then check the checkbox "Parameter".
Free Windows Admin Tool Kit Click here and download it now
June 12th, 2012 2:18am
Well, that does only work if both parameters are from the same dimension e.g. year and calendar week in dimension Time.
But my parameters are from different dimensions!
June 13th, 2012 3:02pm