Forum Discussion
michael_knight
Post Prodigy
4 years agoDate Difference Between two columns and rows
Hi, I'm trying to create a formula which will display the difference between The End Date and the Start Date. This is showing how long it took to start a process after finishing one. In the case ...
- 4 years ago
michael_knight , Try a new column like
Column = var _max1 = maxx(FILTER('Table',[ID] =EARLIER([ID]) && [Start Date] <EARLIER('Table'[Start Date])),[Start Date]) var _max = maxx(FILTER('Table',[ID] =EARLIER([ID]) && [Start Date] =_max1),[End Date] ) return if(ISBLANK(_max), BLANK(), DATEDIFF(_max,[Start Date],DAY))
michael_knight
Post Prodigy
4 years agoHi,
Does anyone know how I can fix the issue above?
Thanks
- amitchandak4 years ago
Super User
michael_knight , Try a new column like
Column = var _max1 = maxx(FILTER('Table',[ID] =EARLIER([ID]) && [Start Date] <EARLIER('Table'[Start Date])),[Start Date]) var _max = maxx(FILTER('Table',[ID] =EARLIER([ID]) && [Start Date] =_max1),[End Date] ) return if(ISBLANK(_max), BLANK(), DATEDIFF(_max,[Start Date],DAY))