MDX Query - return a member contained in the filter

Friday, July 4, 2014

I have an MDX query that is filtering on a particular member, but I need it to return the actual member value as well.


For example:



SELECT NON EMPTY { [Measures].[__No measures defined] } ON COLUMNS, NON EMPTY { ([Archive].[SiteId].[SteId] }ON ROWS FROM [Model] WHERE ( {[Archive].[SiteId].&[{e7672ff4-7f0c-4806-8453-744a17bde4ca}],[Archive].[SiteId].&[{bb7d8f41-c88a-4bcb-ade8-d0533190185a}],[Archive].[SiteId].&[{04cd27b6-e239-4d27-bc58-27f0a8733193}]} )


so in SQL it would basically be -



Select SiteId from Model where SiteId In .....


However this won't work because it says the SiteId Member is already contained in the filter and so appear twice in the query!


So how can filter on SiteId AND return the SiteId?


Thanks!







http://ift.tt/1mQsHap