Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi all,
How would I calculate the time difference between 2 rows depedning on an index column?
Example:
Waste Stop: 2021-03-17 05:52:47
Waste Start: 2021-03-17 06:32:36
Index: 0
Wanted result: time difference (format could be seconds..)
Solved! Go to Solution.
@Anonymous , Create a new column like
new column =
var _max = maxx(filter(Table, [Index] = earlier([Index]) -1 ),[Waste Stop])
return
datediff(maxx(filter(Table, [Index] = earlier([Index]) -1 ),[Waste Stop]),[Waste Start], second)
Just perfect!
Thank you!
@Anonymous , Create a new column like
new column =
var _max = maxx(filter(Table, [Index] = earlier([Index]) -1 ),[Waste Stop])
return
datediff(maxx(filter(Table, [Index] = earlier([Index]) -1 ),[Waste Stop]),[Waste Start], second)
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 98 | |
| 72 | |
| 50 | |
| 50 | |
| 43 |