I am always surprised to discover how many people have been building cubes in SSAS for a while but are unaware of the IgnoreUnrelatedDimensions property. (If you're one of them, watch the SSAS 110 video.) However, someone recently asked me how setting IgnoreUnrelatedDimensions would affect a calculated measure that used measures from more than one measure group. I decided to find out.
First, I created a simple calculated measure that adds two measures from different measure groups. In Adventure Works, I created MyTotalSales like this:
CREATE MEMBER CURRENTCUBE.[MEASURES].[MyTotalSales]
AS [Measures].[Internet Sales Amount]+[Measures].[Reseller Sales Amount],
FORMAT_STRING = "Currency",
VISIBLE = 1;
Note that Internet Sales Amount is in the Internet Sales measure group (MG) and Reseller Sales Amount is in the Reseller Sales MG. Both MGs have IgnoreUnrelatedDimensions set to True, which is the default. If I now construct a query that uses a dimension related to only MG, the results are predictable: The value in the unrelated MG is repeated. The calculated measure is the total of the related measure and the unrelated measure.

Next, I added an attribute from a dimension that isn’t related to either MG. The results:

Next, I set IgnoreUnrelatedDimensions to False for the Reseller Sales MG and reran both queries. For the query with a dimension related to the Internet Sales MG but unrelated to the Reseller Sales MG, the Reseller Sales Amount measure shows as empty as expected. The calculated measure adjusts appropriately:

Next, I ran the query with a dimension unrelated to both MGs. The Reseller Sales Amount measure is blank but the Internet Sales Amount repeats the value:

Finally, I set IgnoreUnrelatedDimensions to False for the Internet Sales MG as well. The query that uses a dimension related to the Internet Sales MG looks the same:

However, when a dimension unrelated to either MG is used, all the values are now blank:

My conclusion is that it doesn’t matter if the calculated measure is in a specific MG or not. What matters is whether or not all measures referenced in the calculated measure belong to MGs that have had IgnoreUnrelatedDimensions to False.