Forum Discussion

iorellano's avatar
iorellano
New Member
2 years ago

Creating a punctuality report

Hi!
I'm working on a reporting tool to calculate the punctuality percentage of a team. 
I'm having issues running the data and finding the right tool, here's what we are working with. 

Log activity: Data that explains every activity for an user

First activity: Min value from log activity

Target clock in: Table explaining clock in times per user. 

The issues i'm running into are: 

* Time data isn't calculated as a value, and it's only read as "count" and "distinct count"

* First activity values are not inputed when using measures and quick measures, it's simply non selectable. 

Thanks for the help!

3 Replies

  • Hi iorellano - can you please provide some sample data to look over ?

     

    Did I answer your question? Mark my post as a solution! This will help others on the forum!
    Appreciate your Kudos!!

  • Anonymous's avatar
    Anonymous
    Not applicable

    Thanks for the reply fromrajendraongole1 ,please allow me to provide another insight:

    HI,iorellano 

    Regarding the issue you raised, my solution is as follows:

    1.First I have created the following table and the column names and data are the data you have given:

    2. Below are the measure I've created for your needs:

    Measure = 
    VAR employ1=CALCULATE(DISTINCTCOUNT('punctuality'[user]),FILTER(ALLSELECTED('punctuality'),'punctuality'[activity id]=MAX('punctuality'[activity id])&&'punctuality'[time]<TIME(9,0,0)))
    VAR employ2=CALCULATE(DISTINCTCOUNT(punctuality[user]),FILTER(ALLSELECTED(punctuality),'punctuality'[activity id]=MAX('punctuality'[activity id])))
    RETURN employ1/employ2

    3.Modify the output format:

    4.Here's my final result, which I hope meets your requirements.

    Can you share sample data and sample output in tabular format if I am misunderstanding? Or a sample pbix after removing sensitive data. We can better understand the problem and help you.

     

    Please find the attached pbix relevant to the case.

     

    Best Regards,

    Leroy Lu

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

     

     

     

    • iorellano's avatar
      iorellano
      New Member

      Punctuality Pbix 

      Good afternoon, and thank you for your interest. The following a simplified version of the data, most important aspects for the task are the first activity metrics and the schedule table.