SQL Server Developer Center >
SQL Server Forums
>
SQL Server Analysis Services
>
Left indentation of report parameters
Left indentation of report parameters
hello,
I need to left indent the values in the Report parameter. I am trying to render the report from SQL Server 2008. my MDX for the parameter is as follows.WITH MEMBER [Measures].[ParameterCaption] AS [X].[Y].CURRENTMEMBER.MEMBER_CAPTION MEMBER [Measures].[ParameterValue] AS [X].[Y].CURRENTMEMBER.UNIQUENAME MEMBER [Measures].[ParameterLevel] AS [X].[Y].CURRENTMEMBER.LEVEL.ORDINAL SELECT {[Measures].[ParameterCaption], [Measures].[ParameterValue],[Measures].[ParameterLevel] } ON COLUMNS , { order ([X].[Z].members,[Measures].[ParameterCaption],basc) } on rows from (select strtoset(@ParameterName) on 0 FROM [ABCCUBE] )Its a multi value report parameter but its not inline with the Select all option. I would be very glad if you can help me in this regard.
Thanks
All Replies
- hi,
this is the one i usually use:
WITH MEMBER [Measures].[ParameterCaption] AS ( [Dimension].[Hierarchy].currentmember.MEMBER_CAPTION ) MEMBER [Measures].[ParameterValue] AS ( [Dimension].[Hierarchy].currentmember.UNIQUENAME ) MEMBER [Measures].[ParameterLevel] AS ( [Dimension].[Hierarchy].currentmember.LEVEL.ORDINAL ) MEMBER [Measures].[ParameterCaptionIndented] AS ( SPACE([Measures].[ParameterLevel]*3) + [Measures].[ParameterCaption] ) SELECT { [Measures].[ParameterCaption], [Measures].[ParameterValue], [Measures].[ParameterLevel], [Measures].[ParameterCaptionIndented]} ON 0, [Dimension].[Hierarchy].members ON 1 FROM [Cube]you have to Replace [Dimension].[Hierarchy] by whatever hierarchy you use on rows
if this varies you can also use this one where [Dimension].[Hierarchy] is derived from the set that is displayed on rows:
(allthought the query might be slower but this usually is not a big problem for parameter-queries)
WITH MEMBER [Measures].[ParameterCaption] AS ( StrToMember(AXIS(1).item(0).properties("HIERARCHY_UNIQUE_NAME")).MEMBER_CAPTION ) MEMBER [Measures].[ParameterValue] AS ( StrToMember(AXIS(1).item(0).properties("HIERARCHY_UNIQUE_NAME")).UNIQUENAME ) MEMBER [Measures].[ParameterLevel] AS ( StrToMember(AXIS(1).item(0).properties("HIERARCHY_UNIQUE_NAME")).LEVEL.ORDINAL ) MEMBER [Measures].[ParameterCaptionIndented] AS ( SPACE([Measures].[ParameterLevel]*3) + [Measures].[ParameterCaption] ) SELECT { [Measures].[ParameterCaption], [Measures].[ParameterValue], [Measures].[ParameterLevel], [Measures].[ParameterCaptionIndented]} ON 0, [Dimension].[Hierarchy].members ON 1 FROM [Cube]hth,
gerhard
- www.pmOne.com - - yah right, I have a problem in the drop down. I have to look into your code.. the drop down shows the values indented to the right except All. So, let me know if you experienced same kind of problem



