Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Sick leave visualization (start and end dates)

Hi everyone! I've been trying to solve the following by my own but I'm way too far of it.   The thing is: I need to analyze some HR data to know which and how many workers are currently with covid ...
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi Anonymous ,

     

    I didn't use the calendar table.

    Firstly, I create a column to get the people on sick leave.

    Is on sick leave = IF([startDate]<=TODAY()&&[endDate]>=TODAY(),"Y","N")

    Then create another column to get the days' remaining who are on sick leave.

    days' remaining = IF([Is on sick leave]="Y",DATEDIFF(TODAY(),[endDate],DAY),BLANK())

     

    Current day is 7/14/2022, the result is below.

     

     

    Best Regards,

    Stephen Tao

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.