Forum Discussion
JohnnyK
Advocate II
5 years agoTo calculate dates difference in the same column, where criteria fits
Good day! Data as below. I want to calculate, for each Project, the difference in days from a "Case Open" (false to true) to File Status" Rejected. In the example, Project KCG’s calculation ...
- 5 years ago
JohnnyK , Create a new column like
new column =
var _1 = maxx(filter(Table, [Edit Date] <earlier([Edit Date]) && [Project] =earlier([Project]) && [Milestone] ="Case Open"),[Edit Date])
return
if(not(isblank(_1)) && [Value after] ="Rejected", datediff(_1, [Edit Date],day), blank())
amitchandak
Super User
5 years agoJohnnyK , Create a new column like
new column =
var _1 = maxx(filter(Table, [Edit Date] <earlier([Edit Date]) && [Project] =earlier([Project]) && [Milestone] ="Case Open"),[Edit Date])
return
if(not(isblank(_1)) && [Value after] ="Rejected", datediff(_1, [Edit Date],day), blank())