COGNOiSe.com - The IBM Cognos Community

IBM Cognos Analytics Platform => Cognos Analytics => Reporting => Topic started by: dbahiker on 20 Feb 2017 03:20:59 PM

Title: Display ALLMEMBERS from SSAS / MDX
Post by: dbahiker on 20 Feb 2017 03:20:59 PM
Is it possible to be able to display ALLMEMBERS from SSAS in Report Studio? Our expression in Report Studio is
roleValue('_memberCaption', [cube_FMS].[Dim FMS Heirarchy].[FMS Reporting Hierarchy].[FMSH FE] )
I get members but not the calculated members that I have created and inserted into the hierarchy in SSAS.

When reviewing the MDX and the only part we need to change it MEMBERS to ALLMEMBERS. to get the results we are looking for.
Title: Re: Display ALLMEMBERS from SSAS / MDX
Post by: AnalyticsWithJay on 21 Feb 2017 08:43:21 AM
Have you tried using the descendants() function? Does it not return calculated members?

EDIT: Something along the lines of descendants([member/level], 0, after self)
Title: Re: Display ALLMEMBERS from SSAS / MDX
Post by: CognosPaul on 21 Feb 2017 01:24:16 PM
This is one of the things that drives me crazy about the MDX engine, we can't specify the specific functions like this. I suspect the main reason is that a lot of these functions are database specific. SSAS and TM1 have a lot of non-MDX standard functions. Why IBM can't make a list of "Native Functions" like you have for databases is beyond me.

I think your best bet here is to create a named set in the cube and reference that. The query optimizer should still work as expected, replacing the named set with [Cube].[Hierarchy].allMembers at runtime.
Title: Re: Display ALLMEMBERS from SSAS / MDX
Post by: dbahiker on 22 Feb 2017 02:32:02 PM
I am trying to use the expression in report studio

roleValue('_memberCaption', [cube_FMS].[Dim FMS Heirarchy].[FMS Reporting Hierarchy].[FMSH FE] )

https://drive.google.com/open?id=0B6YzkoVSAA4mMDRuaEwxRmJ4QV9ZQXpwM2w4UzRPX2ctMVNN
https://drive.google.com/open?id=0B6YzkoVSAA4maV9KMHM3WGpIQy1JQ2VxbXBPX2tNWmM2Z1ZB
Title: Re: Display ALLMEMBERS from SSAS / MDX
Post by: dbahiker on 22 Feb 2017 02:49:38 PM
I think we may have it working with CognosPaul suggestion. Stay tune for update.

Praise COGNOISE LOL!

created a named set in the cube and reference that. The query optimizer should still work as expected, replacing the named set with [Cube].[Hierarchy].allMembers at runtime.

https://drive.google.com/open?id=0B6YzkoVSAA4mckxkUUxBM3RWTFp2ajZnRW00UDNkdThESURZ