+ Reply to Thread
Results 1 to 16 of 16

formula to count a specific word only once in each cell in a column

  1. #1
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    formula to count a specific word only once in each cell in a column

    i have a column where i am counting the word HUD in each cell. unfortunately in some cells it can appear 2 or 3 times. is there a way to count it only once per cell (if it occurs of course)?
    i currently am using =COUNTIF(A:A,"*HUD*"). i am very new at this. any help is very much appreciated.

  2. #2
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: formula to count a specific word only once in each cell in a column

    Your current formula already does that, e.g.

    =COUNTIF(A1:A100,"*HUD*")

    ....will nevre give you a value > 100 because there are only 100 cells in A1:A100
    Audere est facere

  3. #3
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    Quote Originally Posted by daddylonglegs View Post
    Your current formula already does that, e.g.

    =COUNTIF(A1:A100,"*HUD*")

    ....will nevre give you a value > 100 because there are only 100 cells in A1:A100

    i guess i wasn't clear enough. my current formula does work, yes. however, if the word HUD appears 2 or 3 times in the same cell i only want it to count that instance as 1 as opposed to 2 or 3. are you following me?

  4. #4
    Forum Expert Kevin UK's Avatar
    Join Date
    12-07-2010
    Location
    Radstock, Somerset
    MS-Off Ver
    365
    Posts
    1,922

    Re: formula to count a specific word only once in each cell in a column

    Hi Bastet34

    Try:
    =IF(COUNTIF(A:A,"HUD")>1,1,"")
    Regards Kevin


    Merged Cells (They are the work of the devil!!!)

  5. #5
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: formula to count a specific word only once in each cell in a column

    Quote Originally Posted by Bastet34 View Post
    i guess i wasn't clear enough. my current formula does work, yes. however, if the word HUD appears 2 or 3 times in the same cell i only want it to count that instance as 1 as opposed to 2 or 3. are you following me?
    OK, let me check - say column A is blank except for this text in A1

    HUDnnnHUDxxxHUD

    and this text in A2

    HUDnadHUDandHUDand HUD

    Your current formula will give a result of 2 - it counts A1 once and A2 once - isn't that what you want?

  6. #6
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    hi kevin,
    i tried it but there are no results. it's blank (but no errors!).

  7. #7
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    yes, it is. perhaps i was reading the results wrong at the time then? i appreciate both of your help on this!

  8. #8
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    i think i have figured out what the problem is. if i have my formula searching for "TIL", it's pulling until, still, apparently any word w/ TIL in it. the only results i want would contain the exact words i'm looking for. i'm using the same formula as above. is it possible to modify it for exactly just those letters alone? =COUNTIF(A:A,"*TIL*")

  9. #9
    Forum Expert
    Join Date
    12-11-2011
    Location
    Netherlands
    MS-Off Ver
    office 365
    Posts
    3,309

    Re: formula to count a specific word only once in each cell in a column

    Please Login or Register  to view this content.
    Does one of these work?
    Willem
    English is not my native language sorry for errors
    Please correct me if I'm completely wrong

  10. #10
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    i think you've got it with =countif(a:a,"* til *"). the count went down a good bit. i don't have time today to count them by hand for accuracy, but right off it looks good.
    thank you very much popipo

  11. #11
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: formula to count a specific word only once in each cell in a column

    Can you give some representative examples of the text that you might have in column A?

    =countif(a:a,"* til *") will work OK unless you have an entry that begins with "til" or ends with "til".....or if you have punctuation like "til!"
    Last edited by daddylonglegs; 03-12-2013 at 06:04 PM.

  12. #12
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    it appears to have worked daddylonglegs. until is no longer being counted! i also tried typing Tillerman in one of the cells and it did not count it either.
    thanks for the help all!

  13. #13
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: formula to count a specific word only once in each cell in a column

    Yes, it certainly won't count those but my point was that it also won't count Til on its own if Til appears at the start or end of the text like "Til tomorrow"

  14. #14
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    ok, i understand what you mean now. do you want me to email it to you?

  15. #15
    Forum Expert
    Join Date
    12-11-2011
    Location
    Netherlands
    MS-Off Ver
    office 365
    Posts
    3,309

    Re: formula to count a specific word only once in each cell in a column

    =COUNTIF(A:A,"til *")+COUNTIF(A:A,"* til")+COUNTIF(A:A,"til")+COUNTIF(A:A,"* til *")
    Maybe this one for al the possibilities.

  16. #16
    Registered User
    Join Date
    02-26-2013
    Location
    Birmingham, AL
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: formula to count a specific word only once in each cell in a column

    popipipo, =COUNTIF(A:A,"til *")+COUNTIF(A:A,"* til")+COUNTIF(A:A,"til")+COUNTIF(A:A,"* til *") comes back w/ "true".

    daddylonglegs, here's a smalll sample of that column:

    The application date on the HOEPA Form is 10/29/12. Unable to locate the GFE that was disclosed within 3 business days of this date. RESPMIGFE001 - PACKAGE TYPE: Respa Conditions, DOCUMENT TYPE: Good Faith Estimate

    HUD 92900-B Important Notice to Homebuyers page 1

    SRTR - Initial TIL in file is dated more than 10 days prior to application date listed on the HOEPA/HMDA form. None located as being issued within required timeframe. Please provide Initial TIL issued within 10 days of application.

    RTR-The Loan Terms section of the HUD-1 comparison page does not reflect the correct value for the "Your initial amount owed for principal, interest, and any mortgage insurance is" as indicated on the Note, including the monthly mortgage insurance. Please provide the fully completed true and certified copy of the Final HUD. All pages must be provided.
    SRTR-The HOEPA/HMDA Required Information form shows an application date that is the same date as the final execution date of loan documents. Please provide the correct HOEPA/HMDA form.

    Misc Pre-Funding Condition(s)TIL received 2/7/13 was prelim-need signed FINAL TIL

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1