Help with a count statement for multiple criterion

dataAnalystB

New Member
Joined
Apr 16, 2014
Messages
2
I am working with a very large data set where I need to be able to count the number of individuals for a particular position based on either their hired date or termed date. With smaller data sets, I can just sort by hired or termed date, then position, and manually count by selecting the group, but I feel there has to be a more efficient way of doing this can clicking and dragging. Not every line of the data set has a hired date, and of course some of those with hired dates do not have a termination date.

I would appreciate any suggestions on how to write a COUNTIFS statement that looks first at the position and then either Hired or Terminated to deliver the count for that position.

HiredTermedPosition
Position A
1/15/20138/09/2013Position A
7/17/201112/13/2013Position A
Position B
Position B
8/19/2013Position B
1/16/20134/12/2013Position B
3/20/2014Position B
5/22/20104/13/2014Position B
7/23/2012Position C
8/23/20127/15/2013Position C
Position C
9/10/20093/25/2014Position C
Position C

<tbody>
</tbody>




Thank you!
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Would you like the results based on set date i.e. count of person in employment as of today's date?

E.G. Person A would be Zero as 1 has not been hired yet and the other two have been terminated...
 
Upvote 0
I'm sure I'm making this more complex than it needs to be.

Excel Workbook
ABCD
1HiredTermedPosition
2Position A2
308/09/2013Position A2
47/17/201112/13/2013Position A2
5Position B4
6Position B4
78/19/2013Position B4
81/16/201304/12/2013Position B4
93/20/2014Position B4
105/22/20104/13/2014Position B4
117/23/2012Position C3
128/23/20127/15/2013Position C3
13Position C3
1409/10/20093/25/2014Position C3
15Position C3
Sheet1
 
Upvote 0
Tried to do it using Sumproduct but failed..... need to learn more.

so I built on the post by BrianMH


Excel 2010
ABCDEF
1At at16/04/2014
2
3HiredTermedPositionPositionCount
401/01/2001Position APosition A1
515/01/201309/08/2013Position APosition B2
617/07/201113/12/2013Position APosition C2
7Position B
8Position B
919/08/2013Position B
1016/01/201312/04/2013Position B
1120/03/2014Position B
1222/05/201013/04/2014Position B
1323/07/2012Position C
1423/08/201215/07/2013Position C
1510/09/2009Position C
1610/09/200925/03/2014Position C
17Position C
Sheet1
Cell Formulas
RangeFormula
F4{=SUM(--($C$4:$C$17=E4)*--(IF(ISBLANK($A$4:$A$17),$F$1+1,$A$4:$A$17)<=$F$1)*--(IF(ISBLANK($B$4:$B$17),$F$1,$B$4:$B$17)>=$F$1))}
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Thank you both for your input - I'm not strong in syntax, so I'll have to spend some time dissecting these to understand how they work.

The maddening thing about Excel is that it seems like there should be a very simple way to say "If Position equals Position A (B, C, etc.), then count the number of Hires within the Hired Column (or Terminations in Termed)."

I appreciate you taking the time to help, rest assured I'm going to try both suggestions!

Bryan
 
Upvote 0
Thank you both for your input - I'm not strong in syntax, so I'll have to spend some time dissecting these to understand how they work.

The maddening thing about Excel is that it seems like there should be a very simple way to say "If Position equals Position A (B, C, etc.), then count the number of Hires within the Hired Column (or Terminations in Termed)."

I appreciate you taking the time to help, rest assured I'm going to try both suggestions!

Bryan

There are simple ways but the question is very open-ended and can be interpreted multiple ways.
 
Upvote 0

Forum statistics

Threads
1,216,068
Messages
6,128,592
Members
449,460
Latest member
jgharbawi

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