Hi, I am trying to calculate age for a task. Time is in below format. What am I missing? | makeresults | eval Last_Checkin="2021-05-26T20:47:22Z" | table Last_Checkin, _time | eval Age_Days=ceil...
See more...
Hi, I am trying to calculate age for a task. Time is in below format. What am I missing? | makeresults | eval Last_Checkin="2021-05-26T20:47:22Z" | table Last_Checkin, _time | eval Age_Days=ceiling((now()-strptime(Last_Checkin,"%Y-%m-%dT%H:%M:%S%3NZ"))/86400) | eval CVE_Age=case( Age_Days<30,"A_0 to 29 Days", Age_Days>=365,"G_365 Days+", Age_Days>=180,"F_180 to 364 Days", Age_Days>=120,"E_120 to 179 Days", Age_Days>=90,"D_90 to 119 Days", Age_Days>=60,"C_60 to 89 Days", Age_Days>=30,"B_30 to 59 Days", 0==0,"H_No Age Data")