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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Anonymous
Not applicable

Looping through two columns to find the difference between current row and previous row

Hello All,

 

I have a requirement to find the duration between two dates for a particular set of data.

SOLUTION.JPG

 

I need to find the delay between end time of one row to the start time of next row, data will be sorted on the basis of start time, that shows the rank field which I had created.

Solution for delay for category AA should be 18:19:00(end time of 4th row)-18:39:10(start time of 5th row) + 18:41:20(end time of 5th row)-18:47:46(start time of 5th row)+18:56:17(end time of 7th row)-18:59:20( start time of 7th row).Ideally, the end time of first job should be the start time of the second job, if it's not, we should find the delay.In case, end time of the first job is greater than the start time of the second, third or fourth row, the delay should be found between the max of end time between the 4 jobs and start time of the next job.

the logic has to be applicable for each category and subcategory.Ranking is done at job level based on start time of the job.I havent included jobs field here,but rank shows the number of jobs between each sub category.

 

Could you please e resolve this.

0 REPLIES 0

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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