Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.
Hello,
I need some help, I have data from a SQL that gives me total hours (up to 24), I have worked out some of hours by using measure,
Solved! Go to Solution.
Hi @micpete ,
One approach to do this is first converting everyting into minutes, then do the sum, then convert back into hours and minutes. Unfortunately working with durations in DAX is not as convenient as in PowerQuery.
Calcualted column:
TimeMinutes = [hours]*60+[minutes]
Measures:
TotalDuration = SUM(table[TimeMinutes])
TotalHours = INT(DIVIDE([TotalDuration],60))
TotalMinutes = [TotalDuration]-[TotalHours]*60
Kind regards,
Martin
Thank you @Martin_D for your prompt reply.
Hi @micpete ,
May I ask if you have tried the suggestions above? If the suggestion helped you, you might consider marking it as a solution. If the problem has not yet been solved, please feel free to ask us a question.
Best Regards,
Ada Wang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @micpete ,
One approach to do this is first converting everyting into minutes, then do the sum, then convert back into hours and minutes. Unfortunately working with durations in DAX is not as convenient as in PowerQuery.
Calcualted column:
TimeMinutes = [hours]*60+[minutes]
Measures:
TotalDuration = SUM(table[TimeMinutes])
TotalHours = INT(DIVIDE([TotalDuration],60))
TotalMinutes = [TotalDuration]-[TotalHours]*60
Kind regards,
Martin
User | Count |
---|---|
9 | |
8 | |
5 | |
4 | |
3 |