+ Reply to Thread
Results 1 to 5 of 5

Countif, Match and sum?

  1. #1
    Registered User
    Join Date
    08-26-2012
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    14

    Countif, Match and sum?

    Looking for a formula please.

    I have in Col D pairs of names in each cell and in Col E some numbers in each cell. I need to create a NEW column counting the amount of times a partial name appears in Col D and then add the number from Col E associated with it minus 1.

    example: Count how many times "Bob" appears in Col D then on each row in Col D that has a "Bob" total the numbers in Col E then subtract 1

    So the answer to the example above should read 10. Bob=2(from D) +5+3(from E)-1

    COL D COL E
    Bob Champ & Julie Foxx 5
    Vic Black & Geoff Goode 2
    John White & Bob Champ 3

  2. #2
    Forum Expert avk's Avatar
    Join Date
    07-12-2007
    Location
    India
    MS-Off Ver
    Microsoft Office 2013
    Posts
    3,223

    Re: Countif, Match and sum?

    Kindly attach sample file with desired data.


    atul


    If my answer (or that of other members) has helped you, please say "Thanks" by clicking the Add Reputation button at the foot of one of their posts.

    Also: if your problem is solved, please take the time to mark your thread as SOLVED by going to the top of your first post, selecting "Thread Tools" and then "Mark thread as solved".

  3. #3
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,126

    Re: Countif, Match and sum?

    With your example it should return 9 (2+5+3-1)
    =COUNTIF(D:D,"*Bob*")+SUMIF(D:D,"*Bob*",E:E)-1

  4. #4
    Registered User
    Join Date
    08-26-2012
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    14

    Re: Countif, Match and sum?

    Thanks for your help Fluff13. I had to tweak your formula slightly to finally get it. Sorry about the confusion.

    =COUNTIF(D:D,"*Bob*")+SUMIF(D:D,"*Bob*",E:E)-countif(D:D,"*Bob*")

    Cheers!

  5. #5
    Forum Guru
    Join Date
    09-10-2017
    Location
    Chippenham, England
    MS-Off Ver
    365
    Posts
    15,126

    Re: Countif, Match and sum?

    Unless I'm missing something the two parts in blue are just cancelling each other out
    COUNTIF(D:D,"*Bob*")+SUMIF(D:D,"*Bob*",E:E)-countif(D:D,"*Bob*")So you could write it like
    =SUMIF(D:D,"*Bob*",E:E)

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. [SOLVED] Match and countif
    By Yoepy in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 07-08-2018, 10:56 PM
  2. [SOLVED] match # against row, countif -1 otherwise countif
    By jackf-nc in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 07-25-2016, 12:15 AM
  3. [SOLVED] Countif,Match
    By dita87 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-29-2014, 07:35 PM
  4. [SOLVED] How - Match/If/Countif
    By Shermaine2010 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 03-31-2013, 09:30 PM
  5. Replies: 2
    Last Post: 03-16-2012, 12:03 PM
  6. if. match, countif HELP!
    By CHRISB37 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 01-10-2012, 06:56 PM
  7. Match & Countif
    By Killer17 in forum Excel General
    Replies: 4
    Last Post: 12-10-2010, 05:36 AM

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