Web Applications Stack Exchange is a question and answer site for power users of web applications. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a column that sometimes has B and sometimes B - somecomment. I want to count all instances of B. I expected it to be something like

=COUNTIF(B14:B943, LEFT(B14:B943,1) = "B")

But no dice. What am I missing? Is there a better way to solve this problem?

share|improve this question
up vote 2 down vote accepted

Try this:


What you're doing is trying to sum the relevant values before actually running the left() function.

Using arrayformula() will let you evaluate the function over the range and use its output as a single number (basically allows you to run the left() prior to summing the count of "B")

More about using arrayformula(): http://support.google.com/drive/bin/answer.py?hl=en&answer=71291

share|improve this answer

The FILTER function has a way with it as well:


See also small example I've prepared: How to use LEFT function in COUNTIF

share|improve this answer
I don't follow the notation A2:A. Does that mean "start at A2 and include the rest of column A" ? – patrickgamer Nov 18 '12 at 18:16
Indeed, else the header will be included as well. Have you seen my example file? – Jacob Jan Tuinstra Nov 18 '12 at 18:19

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.