Results 1 to 5 of 5

Countif - text begins with the letter __

This is a discussion on Countif - text begins with the letter __ within the Excel Questions forums, part of the Question Forums category; Hi there, I am using a countif formula to answer the question: How many Entries begin with the letter "i"? ...

  1. #1
    New Member
    Join Date
    May 2013
    Posts
    20

    Default Countif - text begins with the letter __

    Hi there,

    I am using a countif formula to answer the question: How many Entries begin with the letter "i"?

    The formula I am using is =countif(left(C2:C101,1),"I") but I am getting an error return

    Do you know what I am doing wrong? How else could I find out how many of the entries begin with the letter "I"?

    Thanks!

    Spinner

  2. #2
    MrExcel MVP Jonmo1's Avatar
    Join Date
    Oct 2006
    Location
    Bryan, TX
    Posts
    32,332

    Default Re: Countif - text begins with the letter __

    You can't apply a function to the range in countif..

    Try using a wildcard

    =COUNTIF(C2:C101,"I*")
    Want better/faster responses to your questions?
    Use Excel Jeanie to post samples of your sheet.

    The more we learn, and the better we get at our trade, the easier it becomes to overlook the obvious.

    Life moves pretty fast. If you don't stop and look around once in a while, you could miss it.
    Ferris Bueller A.K.A. John Hughes, 1986

  3. #3
    New Member
    Join Date
    May 2013
    Posts
    20

    Default Re: Countif - text begins with the letter __

    Ok thanks! I didn't know about wildcards.

    Could I use * to find entries that are only one word entries?

    As an example it would return "Fries" --> One word
    but would not return "Fries and Gravy" --> Three words

    Sppinner

  4. #4
    MrExcel MVP Jonmo1's Avatar
    Join Date
    Oct 2006
    Location
    Bryan, TX
    Posts
    32,332

    Default Re: Countif - text begins with the letter __

    In that case, you would NOT use the wildcard, and just use "Fries"

    =COUNTIF(C2:C101,"Fries")
    Want better/faster responses to your questions?
    Use Excel Jeanie to post samples of your sheet.

    The more we learn, and the better we get at our trade, the easier it becomes to overlook the obvious.

    Life moves pretty fast. If you don't stop and look around once in a while, you could miss it.
    Ferris Bueller A.K.A. John Hughes, 1986

  5. #5
    New Member
    Join Date
    May 2013
    Posts
    20

    Default Re: Countif - text begins with the letter __

    I am trying to apply it to a long range of entries so I would need it to be able to answer the question: How many entries are made up of only one word?

    I'm thinking of something like =countif(c2:c101, and("?*?",not("?*? ?*?")))

    Spinner

Tags for this Thread

Like this thread? Share it with others

Like this thread? Share it with others

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


DMCA.com