Purpose and effect of SSAS hierarchies?

后端 未结 1 1926
执笔经年
执笔经年 2020-12-31 02:58

Firstly, I feel comfortable with what a hierarchy is in terms of the concept and how it impacts the design of a DW\'s star schema. I have some dimensions with lots of attri

相关标签:
1条回答
  • 2020-12-31 04:05

    Not sure 100% the comments I will say applies to SSAS, but as we're both 100% MDX/XMLA compatible it's similar.

    You may start by reading this and the many-to-many documentation.

    The first difference between using hierarchies with levels and attributes is performance. You've two different scenarios for a drilldown (take [Asia] as a particular member and let's find all countries of [Asia]):

    • Using hierarchy with levels : [Asia].children()
    • Using attributes : ([Asia],[Countries])

    The first option is trivial and very fast (the structure is in memory). The second one implies iterating though all countries and 'check' if they exist (aka are countries of [Asia]). This can be a pain for huge attributes (>100k). Once done, we need to go to our fact tables where each members has a set of associated fact rows. The version with a single hierarchy is again direct. The one with two might imply some additional internal operations -> all rows of [Asia] minus the ones of a particular country. Simplified version is also more handy for the cache.

    Second, you define a 'natural' drilldown path that can be directly used in the GUI.

    On top, you can add special aggregations types (First,Last, Min, Max...) that will take into account the structure of a given hierarchy.

    There are successfully OLAP solutions that work without hierarchical structures but you've less features to play with for making a solution.

    I hope it helps you understand these concepts better.

    0 讨论(0)
提交回复
热议问题