problem with parameter in MDX (Expanded hierarchy)

  • I'm trying to make a report with parameters using mdx:

    ="WITH member [measures].[myset] as [Account].[accounting hierarchy].properties('"+Parameters!reportName.Value+"') select {[Measures].[Value],[measures].[myset]} on columns, order(FILTER([Account].[accounting hierarchy].members,[Measures].[myset]),[Measures].[myset],basc) DIMENSION PROPERTIES MEMBER_CAPTION, MEMBER_UNIQUE_NAME, PARENT_UNIQUE_NAME, LEVEL_NUMBER on rows from [FC] where ("+Parameters!unnownDim.Value+")"

    I use OLE DB provider, query works just fine, BUT I get expanded hierarchies as a result in Reporting services, like "Accounting Hierarchy_level_01", "Accounting Hierarchy_level_02",etc. I need to get just simple "Accounting Hierarchy" without any levels or anything else. Any idea how to do it?

    Thanks for help

  • If you need to see the different levels in the hierarchy then there is no way around this unless you ran this through a stored procedure instead using a linked server, Using Reporting Services (SSRS) with SSAS data.

    This is how it will work though in SSRS and SSIS. It will still work the same in the linked server, but you can add logic to condense this down to a single column to use in your reporting.

    The other option would be just to reference a single attribute hierarchy instead of a user defined hierarchy with multiple levels. Then you would only get the single column. If you want the multiple levels then you will need to add some custom logic to evalulate the NULL values to determine what level you are looking at.

    ----------------------------------------------------------------------------------------
    Dan English - http://denglishbi.wordpress.com

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply