Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
How can I create a column that will provide the time elapsed between two cells. For example the difference in time between 1:35:21 and 2:20:47 in the second cell of the column labeled column
Hi @Anonymous ,
How about this?
1. Create a Rank column. Or, you can just add an Index column in Power Query Editor and then use this Index column instead of Rank column in the second expression.
Rank = RANKX('Table','Table'[Date/Time],,ASC,Dense)
2. Create a measure to show the datediff.
Measure =
VAR PreDateTime =
CALCULATE (
MAX ( 'Table'[Date/Time] ),
FILTER ( ALLSELECTED ( 'Table' ), 'Table'[Rank] = MAX ( 'Table'[Rank] ) - 1 )
)
RETURN
DATEDIFF ( PreDateTime, MAX ( 'Table'[Date/Time] ), SECOND )
Please close other unnecessary programs.
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Still running into the issue of power bi endlessly calculating and not creating any results....
Hi @Anonymous ,
Is this problem solved?
Best Regards,
Icey
The formula works, but I am still getting the error of not enough memory
Hi @Anonymous
this column will return you time difference in seconds
Column =
var _prevDate = calculate(max(Table1[Date/Time]);FILTER(ALL(Table1);Table1[Date/Time]<EARLIER([Date/Time])))
RETURN
DATEDIFF(_prevDate;Table1[Date/Time];SECOND)
do not hesitate to give a kudo to useful posts and mark solutions as solution
I am getting the error "There's not enough memory to complete this operation. Please try again later when there may be more memory available."
Any way around this without reducing data size?
@Anonymous 'Clear Cache' from File--> Options
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 40 | |
| 36 | |
| 34 | |
| 31 | |
| 27 |
| User | Count |
|---|---|
| 135 | |
| 103 | |
| 65 | |
| 61 | |
| 55 |