I want to count the number of unique values a column based on COUNTIFS.

maxim642

Board Regular
Joined
Feb 4, 2021
Messages
91
Office Version
  1. 365
Platform
  1. MacOS
I have sickness data, and I want to know how many different colleagues were sick each month. My data includes duplicate values for employee ID as there have been multiple occasions throughout the year that they have been off. I don't want to use a pivot table. Below is an example of my data.

I want to know how many different employees were off in Oct 2021. So unique employee numbers (emp1, emp2 etc.) that are "2021" & "Oct". Thank you.

Emp12021Jan
Emp22019Feb
Emp32021Oct
Emp12021Oct
Emp12021Oct
Emp22021Apr
Emp22020Nov
Emp32021Oct
Emp12020Oct
 

Excel Facts

Wildcard in VLOOKUP
Use =VLOOKUP("Apple*" to find apple, Apple, or applesauce
How about
Excel Formula:
=ROWS(UNIQUE(FILTER(A2:A100,(B2:B100="2021")*(C2:C100="Oct"))))
 
Upvote 0
Solution
You're welcome & thanks for the feedback.
 
Upvote 0

Forum statistics

Threads
1,224,814
Messages
6,181,120
Members
453,021
Latest member
Justyna P

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
Back
Top