Forum Discussion

Graciex123's avatar
Graciex123
Frequent Visitor
3 years ago

Power BI - Dynamic measures inside disconnected table

I have a KPI report with 13 different datasets. For each KPI there is a measure to calculate the actual KPI score which later will be transformed to a score on a scale from 1-5.
There is also a Region/Country/Site core data with relationship to all datasets. So from slicers all of the measures are able to slice on region, country & site.

For my last part of the report I now need to put all of the measure to their corresponding name in a table and from there I need to make a new column with calculations based on the scale.

Example of free from table/disconnected table below

 

 

I have tried this code below as a start to build this but I got stuck now when the measure doesn't filter based on the slicer.

How can I build this table? It needs to be able to calculate the last column (Actual Score after Scaling) based on the measure. But also it needs to respond to the slicers.

 

 

UNION(
ROW("KPI", "Food Waste", "Actual", CALCULATE('Food Waste'[Actual Food Waste],'Site Core Data'[Region] = SELECTEDVALUE('Site Core Data'[Region]))))

 

 

 

2 Replies

  • Hey Graciex123 ,

     

    from my understanding of your requirement is create a calculations group: Introducing Calculation Groups - SQLBI

    Create a calculation item for each measure.

    Create a second calculation group that does the additional calculations.

     

    Hopefully, this provides an idea of how to tackle this challenge.

     

    Regards,

    Tom

    • Graciex123's avatar
      Graciex123
      Frequent Visitor

      I´m not sure if calculation groups would help.
      I have attached this picture. Maybe its easier to explain with this.


      As of now, the table works as a static table. But I want to be able to select region to filter the "actual" column.

      I didn´t know the slicer wouldn´t work with the measures. But is there a workaround for this?