Sickness Calendar

Krash7000

New Member
Joined
Mar 10, 2015
Messages
15
Hi All,

I'm after a bit of help if possible.

I have a list of employees absence's with start date of absence in column A, and end date of absence in column B.

What I want to do is have a list of dates for the year and work off how many employees were off each day.

E.g - Employee A was off from 01/01/20 until 05/01/20, and employee B was off on 04/01/20 - 04/01/20. Data should show as below:
01/01/20 - 1
02/01/20 - 1
03/01/20 - 1
04/01/20 - 2
05/01/20 - 1
 

Some videos you may like

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.

eirikdaude

Board Regular
Joined
Nov 26, 2013
Messages
60
This is fairly easily solved with
Excel Formula:
COUNTIFS
. Assuming the data for FROM is in column A and TO is in column B, you can put the dates for the year in e.g. column D and use a formula like:

Excel Formula:
=COUNTIFS($A$1:$A$2;"<="&$D1;$B$1:$B$2;">="&$D1)

The result should be something like what you see in the screenshot below:
1606988811348.png
 

Krash7000

New Member
Joined
Mar 10, 2015
Messages
15
Thanks for such a quick response! I tried to copy and paste that formula as you had it, but it weirdly doesn't seem to like it when I do it. I am clearly missing something. Sorry!


1606989376442.png
 

Krash7000

New Member
Joined
Mar 10, 2015
Messages
15
I think so. When I write forumlas I use a comma , to separate range from criteria etc.
Sorry, your right. I have changed the formula based on your comment. =COUNTIFS($A:$A,"<="&$D1,$B:$B,">="&$D1) seems to work! Thanks!
 

Watch MrExcel Video

Forum statistics

Threads
1,127,567
Messages
5,625,568
Members
416,118
Latest member
kamil_tuncer

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top