Countifs counting date occurance by Persons name

forest1959

New Member
Joined
Mar 16, 2010
Messages
30
Office Version
  1. 2016
Platform
  1. Windows
Good afternoon

On Sheet 1 I have a list of data, in column A i have a persons name, in column B through to F I have dates that the person is on annual leave, there are multiple names with duplicates in column A

On sheet 2 i have a persons name in cell A2 and a specific date in cell B1, I am trying to count how many times that person has the specific date listed

My formula is

=COUNTIFS(Sheet1!A:A,Sheet2!A2,Sheet1!B:F,Sheet2!B1) but its bringing back #VALUE!

=COUNTIF(Sheet1!A:A,Sheet2!A2) brings back the number of times the persons name is in column A and =COUNTIFS(Sheet1!B:F,Sheet2!B1) counts the number of times the date is located in the 5 columns, but they don't work together

Any idvise please

regards
Paul
 

Attachments

  • Data.PNG
    Data.PNG
    3.6 KB · Views: 31
  • formula.PNG
    formula.PNG
    2.7 KB · Views: 31

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.
What version of Excel are you using?

I suggest that you update your Account details (or click your user name at the top right of the forum) so helpers always know what Excel version(s) & platform(s) you are using as the best solution often varies by version. (Don’t forget to scroll down & ‘Save’)

How about
Excel Formula:
=sumproduct((Sheet1!A$2:A$100=A2)*(Sheet1!B$2:F$100=B1))
 
Upvote 0
Solution
Thanks, Excel 2016 on Windows... I have updated my account details too
 
Upvote 0
and your solution was perfect... Thank you for the prompt response
 
Upvote 0
Glad to help & thanks for updating your profile.
 
Upvote 0

Forum statistics

Threads
1,218,691
Messages
6,143,941
Members
450,516
Latest member
shironokuro

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