Exploring more MDX expressions
Entire books have been written on MDX exclusively. MDX is a very powerful query and expression language. We have touched just a small part of what is possible. This section will present a few additional expressions and techniques for you to practice with. We will primarily be working in SSMS to illustrate both member creation and various query techniques. Any member created in SSMS can be moved to the cube, as we have demonstrated throughout this chapter.
Traversing hierarchies
Earlier in the chapter, we talked about how traversing the cube is like working with a family tree. Functions such as parent, children, ancestor, descendant, and even cousin exist in MDX. Here are some examples for you to use with our cube.
members
members
returns all the members of a level or hierarchy depending on the context. We have used members
in several queries already. Let's look at the City
dimension for an easy example of using members
. We can use members...