+ Reply to Thread
Results 1 to 10 of 10

Help needed for lookup and sum

  1. #1
    Registered User
    Join Date
    08-07-2015
    Location
    Manchester, England
    MS-Off Ver
    2013
    Posts
    5

    Help needed for lookup and sum

    Please does anyone have a forumula to perform the below actions in the attached photo spreadsheet:

    Lookup the word "Dedert" in column B and then add up the values of the CPMU in D2, D5, D8, etc.
    This will also need to work for other names in column B.

    Any help would be appreciated!

    Capture.PNG

  2. #2
    Forum Contributor
    Join Date
    07-13-2015
    Location
    Quebec, Canada
    MS-Off Ver
    2013
    Posts
    232

    Re: Help needed for lookup and sum

    A picture does not help much. Could you instead attach a file?

    Also, are those merged cells?

    It's hard to help since we don't know where you're taking your information, etc

  3. #3
    Forum Expert daffodil11's Avatar
    Join Date
    07-11-2013
    Location
    Phoenixville, PA
    MS-Off Ver
    MS Office 2016
    Posts
    4,465

    Re: Help needed for lookup and sum

    =SUMIF(B2:B14,"dedert",D2:D14)
    =SUMIFS(D2:D14,B2:B14,"dedert",C2:C14,"CPMU")
    =SUMPRODUCT((B2:B14="DEDERT")*(D2:D14))
    =SUMPRODUCT((B2:B14="DEDERT")*(C2:C14="CPMU")*(D2:D14))

    I'm hoping to find a non-array solution to coerce values with N. Where's Snorlax when you need him?
    Last edited by daffodil11; 08-07-2015 at 11:07 AM.
    Make Mom proud: Add to my reputation if I helped out!

    Make the Moderators happy: Mark the Thread as Solved if your question was answered!

  4. #4
    Valued Forum Contributor nigelbloomy's Avatar
    Join Date
    11-06-2013
    Location
    USA
    MS-Off Ver
    Excel 2010
    Posts
    1,011

    Re: Help needed for lookup and sum

    This could work if you can get rid of those error cells.
    Please Login or Register  to view this content.
    Some people volunteer in soup kitchens or hospitals. I choose to make the world better by trying to help you with Excel. We're all learning.

    <---Click * Add Reputation for all helpful comments. It's like giving a smile.
    Forum Rules: How to mark your post [Solved] and have a happier, Excel enriched life.

  5. #5
    Registered User
    Join Date
    08-07-2015
    Location
    Manchester, England
    MS-Off Ver
    2013
    Posts
    5

    Re: Help needed for lookup and sum

    Sorry about that. Do you need the full file or will a cut and paste of the necessary section suffice? Yes they are merged cells.
    Attached Files Attached Files

  6. #6
    Forum Expert daffodil11's Avatar
    Join Date
    07-11-2013
    Location
    Phoenixville, PA
    MS-Off Ver
    MS Office 2016
    Posts
    4,465

    Re: Help needed for lookup and sum

    Maybe a brighter mind can come up with something non-array. I need coffee.

    =SUMPRODUCT(--IFERROR((B2:B20="DEDERT")*(C2:C20="CPMU")*(D2:D20),0))

    ...confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. You will know the array is active when you see curly braces { } appear around your formula. If you do not CTRL+SHIFT+ENTER you will get an error or a clearly incorrect answer. Press F2 on that cell and try again.

  7. #7
    Registered User
    Join Date
    08-07-2015
    Location
    Manchester, England
    MS-Off Ver
    2013
    Posts
    5

    Re: Help needed for lookup and sum

    This worked a treat! Thank you so much for your help!

  8. #8
    Registered User
    Join Date
    08-07-2015
    Location
    Manchester, England
    MS-Off Ver
    2013
    Posts
    5

    Re: Help needed for lookup and sum

    Sorry to bother you again.. I've tried to alter the formula slightly to get the same result but with "Complaints" (in C column) instead of "CPMU" and it just returns a 0 figure. Am I missing something or is it not that simple?

    Thanks in advance.

  9. #9
    Forum Expert daffodil11's Avatar
    Join Date
    07-11-2013
    Location
    Phoenixville, PA
    MS-Off Ver
    MS Office 2016
    Posts
    4,465

    Re: Help needed for lookup and sum

    SUMPRODUCT works by multiply like-amount arrays against one another to check criteria.

    You'll need to adjust the array by one cell to achieve the same result.

    =SUMPRODUCT(--IFERROR((B2:B20="DEDERT")*(C3:C21="Complaints")*(D3:D21),0))

    As long as the ranges contain the same number of cells for this type of comparison, it doesn't matter that they are offset.

    B2:B20 = 19 cells
    C3:C21 = 19 cells

    I've attached a tutorial on SUMPRODUCT to illustrate.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    08-07-2015
    Location
    Manchester, England
    MS-Off Ver
    2013
    Posts
    5

    Re: Help needed for lookup and sum

    You're very kind. Thanks again!

+ 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. Lookup help needed
    By stowslee in forum Excel General
    Replies: 18
    Last Post: 05-26-2015, 01:08 AM
  2. h-lookup, v-lookup formula needed
    By rishijain11 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 05-06-2014, 03:28 PM
  3. Replies: 3
    Last Post: 05-05-2014, 11:31 AM
  4. Lookup help needed
    By Bl00m in forum Excel General
    Replies: 4
    Last Post: 01-22-2013, 09:21 AM
  5. Lookup help needed
    By lukiebabie in forum Excel General
    Replies: 1
    Last Post: 11-28-2011, 10:40 AM
  6. Help needed with a Lookup
    By Carlos the blue in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 12-18-2006, 09:33 AM
  7. Lookup help needed
    By atran in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-22-2005, 04:24 PM

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