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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
samanthabelfy
New Member

Calculate number of hours that are overlapping

I have a table of data with dates and times and need to calculate the number of hours that are overlapping. I've seen resources for dates but nothing really with dates and times. Any help would be so appreciated!

 

samanthabelfy_0-1724944804764.png

 

3 REPLIES 3
Omid_Motamedise
Super User
Super User

What do you mean overlaping, you ,want to calculation duration per each row or overlaping of different rows?

If my answer helped solve your issue, please consider marking it as the accepted solution. It helps others in the community find answers faster—and keeps the community growing stronger!
You can also check out my YouTube channel for tutorials, tips, and real-world solutions in Power Query with the following link
https://youtube.com/@omidbi?si=96Bo-ZsSwOx0Z36h

I need to calculate the number of hours that overlap between all of the rows. 

jgeddes
Super User
Super User

I have attached a .pbix file that has a potential solution for you, though I am not certain how quickly it will run on an actual dataset.
As a small example I started with...

jgeddes_0-1724951505620.png

and end up with...

jgeddes_1-1724951545921.png

The general idea is to create a list of billed minutes for each entry. Take the generated list of billed minutes for each entry and group them together so you will know which billed minutes have multiple entries. From there I did some table transformations to get the overlapping entries listed for each billed minute. Then grouped by overlapping entries, some more transfomations to format the results and then merge that table back into the main table.





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

Proud to be a Super User!





Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors