Is the Tuple in MDX an implicit crossjoin?
-
10-07-2019 - |
Question
Are the two statements equivalent?
Tuple:
SELECT {[Measures].[Volume]} ON COLUMNS,
([Product].[Product Id].[Product Id].AllMembers
,[Time].[Time].[Year].AllMembers) ON ROWS
FROM [My Cube]
Versus explicit crossjoin:
SELECT {[Measures].[Volume]} ON COLUMNS,
[Product].[Product Id].[Product Id].AllMembers
* [Time].[Time].[Year].AllMembers ON ROWS
FROM [My Cube]
They seem to return the same result, but it seemed from the reading I have done that they shouldn't (at least not always).
Solution
What you have in your first query is not a tuple. Tuples are made up of a collection of one or more members
eg. (member1, member2, ...)
Where as what you have is (set1, set2 ...). which I think of as a subcube as this is what is use when defining subcubes for scope statements. And a subcube is essentially an implied crossjoin, so your two queries should return the same result.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow