replace the explicit naming so that the group structure is build dynamically

  • I have an hierarchy bp_groups that consists of 5 levels

    I want to write MDX that shows the complete structure of the group. The example below uses the .children to expand the lowest level. As members of a group often change it is not a good idea to name them explicitly ([300001738],[300002148]). My question is : How can i replace the explicit naming ([300001738],[300002148]) so that the group structure is build dynamically, and is alway's up-to-date?

    select NON EMPTY {([Year.Year/Month/Date].[All Year/Month/Date].[2001], [Measures].[Gross sales])} ON COLUMNS,

    NON EMPTY

    Hierarchize(Union(Union(Union(

    {[BP_groups.BP(id+name)].[All BP_groups.BP(id+name)s].[300002370]},

    [BP_groups.BP(id+name)].[All BP_groups.BP(id+name)s].[300002370].Children),

    [BP_groups.BP(id+name)].[All BP_groups.BP(id+name)s].[300002370].[300001738].Children),

    [BP_groups.BP(id+name)].[All BP_groups.BP(id+name)s].[300002370].[300002148].Children)) ON ROWS

    from [salescube]

  • Do you have any data source that determines what the grouping members are? Not sure it'll work in your case, but assuming you *do* have that datasource, and you *don't* already have a parent-child hierarchy defined in the dimension, you could just add the parent child hierarchy and then on re-process of the dimension (and therefore the P-C hierarchy data also) your hierarchy would reflect the current state of the grouping data.

    Steve.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply