Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
I have an issue with a report. I am looking to see the repairs per hour. The sample data set I am working with is below. I want to see the repairs per hour by owner but I can't seem to figure it out. I haven't had any real training Power BI and I am learning as i go. Please help me out.
Work Order | Serial number | Created on | Completed On | Owner |
WO54318 | A1 | 4/11/24 1:17 PM | 4/11/24 1:24 PM | Scott Peterson |
WO54319 | A2 | 4/11/24 1:54 PM | 4/11/24 2:08 PM | Scott Peterson |
WO54320 | A3 | 4/11/20242 2:15 PM | 4/11/20242 2:22 PM | Scott Peterson |
WO54321 | A4 | 4/11/24 2:24 PM | 4/11/24 2:31 PM | Mark Dobson |
WO54322 | A5 | 4/11/24 2:38 PM | 4/11/24 2:59 PM | Scott Peterson |
WO54323 | A6 | 4/11/24 3:17 PM | 4/11/24 3:21 PM | Mark Dobson |
WO54324 | A7 | 4/11/24 3:22 PM | 4/11/24 3:32 PM | Mark Dobson |
WO54325 | A8 | 4/11/24 3:36 PM | 4/11/24 3:42 PM | Mark Dobson |
WO54326 | A9 | 4/11/24 3:44 PM | 4/11/24 3:49 PM | Scott Peterson |
WO54327 | A10 | 4/11/24 3:50 PM | 4/11/24 3:57 PM | Mark Dobson |
WO54328 | A11 | 4/11/24 3:58 PM | 4/11/24 4:01 PM | Scott Peterson |
WO54329 | A12 | 4/11/24 4:05 PM | 4/11/24 4:12 PM | Scott Peterson |
WO54330 | A13 | 4/11/24 4:14 PM | 4/11/24 4:20 PM | Scott Peterson |
WO54331 | A14 | 4/11/24 4:21 PM | 4/11/24 4:30 PM | Tyler Richardson |
WO54332 | A15 | 4/11/24 4:32 PM | 4/11/24 4:47 PM | Tyler Richardson |
WO54333 | A16 | 4/11/24 4:51 PM | 4/11/24 4:59 PM | Tyler Richardson |
Solved! Go to Solution.
It would be great if you could provide more clarity on the logic for calculating a repair.
As of now, I have taken the following assumption:
Repair duration = Time difference in minutes between "Created On" and "Completed On"
Thus, I created a calculated column in the table as follows, that calculates the repair duration in Minutes:
Duration = DATEDIFF(Repairs[Created on],Repairs[Completed On],MINUTE)
I have then used the "Duration" measure to calculate number of repairs in a minute and then on a hour. Here is the measure:
Repairs per Hour =
VAR _repairPerMinute = DIVIDE(COUNT(Repairs[Work Order]),SUM(Repairs[Duration]))
VAR _repairPerHour = _repairPerMinute * 60
RETURN
ROUND(_repairPerHour, 0)
If my assumption is correct then you can use this measure and it should solve your problem. Here is screenshot of the result:
In case, this is not something that you expect, kindly provide the following details:
- A logic for the repair duration calculation
- A sample anonymized dataset
- A sample image/data of the expected answer
Best Regards,
Udit
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudo 👍
🚀 Let's Connect: LinkedIn || YouTube || Medium || GitHub
✨ Visit My Linktree: LinkTree
It would be great if you could provide more clarity on the logic for calculating a repair.
As of now, I have taken the following assumption:
Repair duration = Time difference in minutes between "Created On" and "Completed On"
Thus, I created a calculated column in the table as follows, that calculates the repair duration in Minutes:
Duration = DATEDIFF(Repairs[Created on],Repairs[Completed On],MINUTE)
I have then used the "Duration" measure to calculate number of repairs in a minute and then on a hour. Here is the measure:
Repairs per Hour =
VAR _repairPerMinute = DIVIDE(COUNT(Repairs[Work Order]),SUM(Repairs[Duration]))
VAR _repairPerHour = _repairPerMinute * 60
RETURN
ROUND(_repairPerHour, 0)
If my assumption is correct then you can use this measure and it should solve your problem. Here is screenshot of the result:
In case, this is not something that you expect, kindly provide the following details:
- A logic for the repair duration calculation
- A sample anonymized dataset
- A sample image/data of the expected answer
Best Regards,
Udit
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudo 👍
🚀 Let's Connect: LinkedIn || YouTube || Medium || GitHub
✨ Visit My Linktree: LinkTree
I am looking to be able to calculate repairs per hour by owner. I dont have any other time metrics to use other than created on and completed on. I am going to run the logic built and update after. I am sorry I can't give more.
No problem,
Just try the solution and let me know if it solves your issues.
Happy to help 😊
Best Regards,
Udit
If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudo 👍
🚀 Let's Connect: LinkedIn || YouTube || Medium || GitHub
✨ Visit My Linktree: LinkTree
This works! Thank you for the help!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
21 | |
15 | |
14 | |
11 | |
7 |
User | Count |
---|---|
26 | |
24 | |
12 | |
11 | |
10 |