How do I dynamically get all the levels I need in MDX? -
09-06-2004
, 05:51 PM
I need to modify my MDX query so that I get all the levels for a
particular dimesnion.
In the following query, I get all the levels in my ProdHierarchy
dimension, starting at level 04. However, there are times when there
may be a different number of levels. How do I dynamically get all the
members without specifying a particular level to start from? The part
of the query below I would need to modify is "[ProdHierarchy].[Level
04].ALLMEMBERS". I'm terrible at MDX and would appreciate any help
using a specific example. Thanks.
SELECT { [Measures].[Amt Sold], [Measures].[Num Sold] } ON COLUMNS, {
(YTD([TimeDimension].[2004].[Quarter 4].[December]) *
[ProdHierarchy].[Level 04].ALLMEMBERS) } DIMENSION PROPERTIES
MEMBER_CAPTION ON ROWS FROM [Sales] |