Forum Discussion

SampathGiriDN's avatar
SampathGiriDN
Frequent Visitor
4 years ago
Solved

Count number of Risks under 2 different categories in 2 different columns, 2 tables - Matrix visual

matrix   Hi Everyone, I am new to Power BI and I am need of urgent help with below to create a Heat Map using a Matrix Visual. I have 2 tables Table 1 - Risk Summary Table having below columns ...
  • johnt75's avatar
    4 years ago

    You could use bookmarks which show & hide only 1 version of the table and then have a button which flips the bookmark

  • v-chenwuz-msft's avatar
    4 years ago

    Hi SampathGiriDN ,

     

    You can try these steps.

    1 Unpivot the Table 2. Let it like this ( select IDs and unpivot other columns):

     

    2 Configure the relationship between Table1 and Table2, Cross filter direction to both.

    3 Create a new table via distinct(union(VALUES('Table 1'[Inherent Impact Level]),VALUES('Table 1'[Residual Impact Level]))):

    4 Last, create a tag measure named if_1:

     

    if_1 = 
    SWITCH(TRUE(),
    ISFILTERED('Table 1'[Inherent Risk Level])&&SELECTEDVALUE('Table 2'[Attribute])="Inherent Probability Level",1,
    ISFILTERED('Table 1'[Residual Risk Level])&&SELECTEDVALUE('Table 2'[Attribute])="Residual Probability Level",1,
    not(OR(ISFILTERED('Table 1'[Residual Risk Level]),ISFILTERED('Table 1'[Inherent Risk Level])))&&SELECTEDVALUE('Table 2'[Attribute])="Residual Probability Level",1,0)

     

    Put this tag in matrix table's filter pane and set show items is 1

     

     

    Pbix in the end you can refer.

    Best Regards

    Community Support Team _ chenwu zhu

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.