Forum Discussion

mg's avatar
mg
New Member
8 years ago
Solved

Parent / Child Relation + Multiply

Hi !   Ive the following table.  Ive succeeded with Power BI to sum for A (=B+F) and B(=C+D+E) through a parent / child relationship.  Nevertheless, i wd like to add a mark-up on A and B meaning ...
  • Anonymous's avatar
    Anonymous
    8 years ago

    HI mg,

     

    I'd like to suggest you take a look at below link which mentioned about how to use path function to create custom hierarchy for analysis.

    Parent-Child Hierarchies

     

    Sample:

    Level 1 =
    VAR replaced =
        SUBSTITUTE ( [PathID], " ", "" )
    RETURN
        PATHITEM ( SUBSTITUTE ( replaced, "/", "|" ), 1 )
    	
    Level 2 =
    VAR replaced =
        SUBSTITUTE ( [PathID], " ", "" )
    RETURN
        PATHITEM ( SUBSTITUTE ( replaced, "/", "|" ), 2 )
    	
    Level 3 =
    VAR replaced =
        SUBSTITUTE ( [PathID], " ", "" )
    RETURN
        PATHITEM ( SUBSTITUTE ( replaced, "/", "|" ), 3 )

    Add hierarchy columnCreate custom hierarchyCreate matrix visual

     

    Notice: I add visual level filter to remove blank value.

     

    Regards,

    Xiaoxin Sheng