Forum Discussion
LuizMartins
4 years agoRegular Visitor
help calculate duration between lines
Hi guys, I need some help. I have a data file where I need to calculate the duration between lines. In excel I use the simple formula. I would like to do the same directly in powerbi.
Any suggestion?
thanks
LuizMartins , Add an index column in power query
Power Query- Index Column: https://youtu.be/NS4esnCDqVw
Then create a new column
datediff(maxx(filter(Table, [Index] = earlier([Index]) -1) ,[B]), [B], second)
2 Replies
- amitchandakSuper User
LuizMartins , Add an index column in power query
Power Query- Index Column: https://youtu.be/NS4esnCDqVw
Then create a new column
datediff(maxx(filter(Table, [Index] = earlier([Index]) -1) ,[B]), [B], second)
- LuizMartinsRegular Visitor
Perfect! Thank you very much!!