countif question (posted recently in wrong location - sorry)

%3CLINGO-SUB%20id%3D%22lingo-sub-2530608%22%20slang%3D%22en-US%22%3Ecountif%20question%20(posted%20recently%20in%20wrong%20location%20-%20sorry)%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2530608%22%20slang%3D%22en-US%22%3E%3CP%3EIs%20there%20a%20way%20to%20use%20countif%20to%20count%20the%20number%20of%20cells%20in%20a%20column%20that%20are%20older%20than%20the%20first%20date%20of%20the%20current%20year.%26nbsp%3B%20(countif(C%3AC%2C%22%26gt%3B%3D1%2F1%2F2021%22)%20works%20but%20i%20don't%20want%20to%20have%20to%20change%20formula%20annually.%26nbsp%3B%20I%20already%20have%20a%20cell%20with%20today()%20in%20it%20and%20would%20like%20to%20reference%20it.%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2530608%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EFormulas%20and%20Functions%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EOffice%20365%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2530791%22%20slang%3D%22en-US%22%3ERe%3A%20countif%20question%20(posted%20recently%20in%20wrong%20location%20-%20sorry)%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2530791%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1078878%22%20target%3D%22_blank%22%3E%40HRGuru55%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3EAssuming%20your%20TODAY()%20function%20is%20in%20A1%3A%3C%2FP%3E%3CPRE%20class%3D%22lia-code-sample%20language-excel%22%3E%3CCODE%3E%3DCOUNTIF(C%3AC%2C%22%26gt%3B%3D%22%20%26amp%3B%20A1)%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2533197%22%20slang%3D%22en-US%22%3ERe%3A%20countif%20question%20(posted%20recently%20in%20wrong%20location%20-%20sorry)%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2533197%22%20slang%3D%22en-US%22%3ELz%2C%20that%20is%20counting%20every%20cell%20that%20is%20less%20than%20today%20because%20A1%20is%20today.%20I%20need%20the%20function%20that%20creates%20the%20first%20day%20of%20the%20year%2C%20regardless%20of%20what%20day%20of%20the%20year%20it%20is.%3CBR%20%2F%3EI%20am%20trying%20to%20count%20the%20number%20of%20people%20who%20were%20hired%20prior%20to%20January%201st%3CBR%20%2F%3ECan%20i%20use%20a%20function%20in%20an%20adjacent%20cell%20(ie...B1)%20that%20will%20always%20be%20Jan%201%2C%20xxxx%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2533244%22%20slang%3D%22en-US%22%3ERe%3A%20countif%20question%20(posted%20recently%20in%20wrong%20location%20-%20sorry)%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2533244%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1078878%22%20target%3D%22_blank%22%3E%40HRGuru55%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%0A%3CP%3EIt%20could%20be%3C%2FP%3E%0A%3CPRE%20class%3D%22lia-code-sample%20language-excel%22%3E%3CCODE%3E%3DCOUNTIF(C%3AC%2C%20%22%26lt%3B%22%20%26amp%3B%20DATE(YEAR(TODAY())%2C1%2C1)%20)%3C%2FCODE%3E%3C%2FPRE%3E%3C%2FLINGO-BODY%3E
Contributor

Is there a way to use countif to count the number of cells in a column that are older than the first date of the current year.  (countif(C:C,">=1/1/2021") works but i don't want to have to change formula annually.  I already have a cell with today() in it and would like to reference it. 

4 Replies

@HRGuru55 

Assuming your TODAY() function is in A1:

=COUNTIF(C:C,">=" & A1)
Lz, that is counting every cell that is less than today because A1 is today. I need the function that creates the first day of the year, regardless of what day of the year it is.
I am trying to count the number of people who were hired prior to January 1st
Can i use a function in an adjacent cell (ie...B1) that will always be Jan 1, xxxx

@HRGuru55 

It could be

=COUNTIF(C:C, "<" & DATE(YEAR(TODAY()),1,1) )
I obvously misunderstood something - Thanks @Sergei Baklan