Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
VivekBusi03
Frequent Visitor

Working Hours in power query

Hi All, 
I got stuck at a task which I was trying in Power Query. I have 2 columns (times) "LogOut" & "LogIn". Based on these columns I need a new column which shows the Time period between the "LogOut" & "LogIn" columns.

VivekBusi03_0-1661345929529.png

Thank You!

2 REPLIES 2
jgeddes
Super User
Super User

Table.AddColumn(#"Changed Type1", "workingHours", each Duration.From([logout]) - Duration.From([login]))

will work as long as the login and logout columns are text type, not time type.




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

Proud to be a Super User!





Hi @jgeddes ,
Thanks for you the reply, I really appreciate for the solution.
But it's throwing an error. at the end.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.