In the OLAP database, I work with the "Location" hierarchy, which consists of the levels Company, Region, Area, Site, Room, Till. For a specific company, I need to write several MDXs that list all regions, areas and sites (but not all levels below the Site). I am currently achieving this with the following MDX
HIERARCHIZE({
[Location].[Test Company],
Descendants([Location].[Test Company], [Location].[Region]),
Descendants([Location].[Test Company], [Location].[Area]),
Descendants([Location].[Test Company], [Location].[Site])
})
Since my knowledge of MDX is limited, I was wondering if there is an easier way to do this, with one command and not four? Is there a less sure way to achieve this, or is my example the only real way to achieve this?
source
share