Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Count only fields with text/data, not formulas

Tags:

excel

count

I have a listing of headcount within a given month that I am comparing to budgeted headcount. I have used a vlookup to match budget to actuals. Then: =IF(ISNA(M66),K66," ") to return names that are not in budget, but in actuals (HR file) or else blank.

Now I would like to count the names returned in the column , but I'm having trouble with the count functions recognizing the formula in the cells even though they are blank.

Thanks for your time!

like image 776
timothy smith Avatar asked Feb 25 '13 21:02

timothy smith


2 Answers

[Edit - didn't notice the space in " " - remove that as Scott suggests then try below]

If range of data is A2:A100 try this formula to count text values but not ""

=COUNTIF(A2:A100,"?*")

or if you want to include numeric values too

=SUMPRODUCT((A2:A100<>"")+0)

like image 139
barry houdini Avatar answered Nov 09 '22 12:11

barry houdini


COUNTA(A2:A100,"")-COUNTA(A2:A100)
like image 36
Champukuta Avatar answered Nov 09 '22 11:11

Champukuta