Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Create KPI in power bi (please help)

Hi Expert,

I have a need to create KPI in power bi.

i import KPI model from tabular which looks like this. total 6 KPI.

 

how to create KPI that link to my main data table?

 

i have uploaded a pbix file, link

https://1drv.ms/u/s!AjpB2wk5YDY3hwObjTB22ZdetGwb?e=UwyIVA

 

Can anyone have a look please?

i can't really find similar solved posts can apply to my problem.

 

Thanks

 

 

 

 

 

 

  • Hi Anonymous ,

     

    I'm not understading what is the result you need on this, do you want to have the calculation of these KPI's based on the tables you have on your model? Do you need to have this KPI's comparing to some values on your other tables?

     

    Can you please elaborate, so I can assist you better.

4 Replies

  • Hi Anonymous ,

     

    I'm not understading what is the result you need on this, do you want to have the calculation of these KPI's based on the tables you have on your model? Do you need to have this KPI's comparing to some values on your other tables?

     

    Can you please elaborate, so I can assist you better.

    • Anonymous's avatar
      Anonymous
      Not applicable

      HI MFelix thanks for replying.

       

      here's one KPI - reliability as an example

      i have a daily service data table imported from SQL server. 

      my actual reliability% is a measure = 

      ([First Departure]-[Services Cancelled])/[First Departure]
       
      First Departure = CALCULATE(COUNTROWS('COMPASS VU_DailyServices'),FILTER('COMPASS VU_DailyServices','COMPASS VU_DailyServices'[First Departure]=1))
       
      Services Cancelled = CALCULATE(COUNTROWS('COMPASS VU_DailyServices'),FILTER('COMPASS VU_DailyServices','COMPASS VU_DailyServices'[OVERALL_CANCELLATION]=1),FILTER('COMPASS VU_DailyServices','COMPASS VU_DailyServices'[First Departure]=1))
       
      i also imported tabular KPI model, you can find the screenshot in my original post. 
      in the kpi model - reliability is 0.98, but for somehow when i drag this kpi into kpi indicator, just doesn't work.
       
       
      my goal is to create a Reliability KPI which is 98% in power bi
      so I can use KPI indicator or other line charts to present each location their Reliability performance against KPI
       
      the link you can download my sample pbix if that helps.
       
       
       

       

       

       

      • MFelix's avatar
        MFelix
        Super User

        Hi Anonymous ,

         

        Believe this is related with your relationships, besides the dates how do the KPI's relate with your other tables. This is a context issue, wheere you need to have the relationship's matching the expected result otherwise you can have one of two results sum of all values in the table or no result at all (this last one is what you are getting).

         

        Believe you need to create a Calendar table alonside with some other dimensions so you can have the model returning the correct results.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thank you i'll have a look into it.