cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
tiagotas Regular Visitor
Regular Visitor

View and add up to 24 hours!

I need to create a panel where I visualize the sum of hours worked, and these hours are mostly over 24 hours. Ex: 36:00 hours. Can I use this format in Power Bi?

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: View and add up to 24 hours!

Yes, you split that field by the separator: ":" into 2 fields: First "Hours", second "Minutes". Perform all aggregations and transformations on these 2 fields separately before in the last step, you add them together again to create the total field, this time in a decimal format.

Did I answer your question? Mark my post as a solution!

Proud to be a Datanaut!

Imke Feldmann

How to integrate M-code into your solution -- Check out more PBI- learning resources here -- Performance Tipps for M-queries




View solution in original post

2 REPLIES 2
Super User
Super User

Re: View and add up to 24 hours!

Yes, you split that field by the separator: ":" into 2 fields: First "Hours", second "Minutes". Perform all aggregations and transformations on these 2 fields separately before in the last step, you add them together again to create the total field, this time in a decimal format.

Did I answer your question? Mark my post as a solution!

Proud to be a Datanaut!

Imke Feldmann

How to integrate M-code into your solution -- Check out more PBI- learning resources here -- Performance Tipps for M-queries




View solution in original post

Moderator v-caliao-msft
Moderator

Re: View and add up to 24 hours!

Hi @tiagotas,

 

In your scenario, you can use DATEDIFF function to get the total hours for each employee, this value can exceed 24 hours.

Reference
https://msdn.microsoft.com/en-us/library/dn802538.aspx

 

If this is not what you want, please provide us some sample data and expected result, so that we can make further analysis.

 

Regards,

Charlie Liao

 

Helpful resources

Announcements
Ask Amir Anything

Exclusive LIVE Community Event No. 2 – Ask Amir Anything

Next in our Triple A series: Ask Amir Netz questions about the latest updates, features and future.

October 2019 Community Highlights

October 2019 Community Highlights

October was a busy month in the community. Read the recap article to learn about some of the events and content.

New Solution Badges

New Solution Badges

Two waves of brand new solution badges are coming! Read the article for more information on our new community badges.

Analytics in Azure virtual event

Analytics in Azure virtual event

Experience a limitless analytics service built to ingest, prep, manage, and serve data for immediate use in Power BI.

Users Online
Currently online: 128 members 1,636 guests
Please welcome our newest community members: