+ Reply to Thread
Results 1 to 14 of 14

Sumifs give zero result

  1. #1
    Forum Contributor
    Join Date
    02-24-2015
    Location
    Egypt
    MS-Off Ver
    Office 365 ProPlus
    Posts
    774

    Sumifs give zero result

    Hello everybody,
    Could you help me in my question ,please?
    Sumifs formulas gives zero if there are multiple criteria.The formula is found in G7
    Office version: Office 365
    see the attachment
    Attached Files Attached Files

  2. #2
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Sumifs give zero result

    Your formula is asking sumifs to return a value when a cell in column B contains BOTH F3 & F4 which is illogical.
    Use instead

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,427

    Re: Sumifs give zero result

    You can do it like this in G7:

    =SUMIFS($D$4:$D$17,$B$4:$B$17,F3)+SUMIFS($D$4:$D$17,$B$4:$B$17,F4)

    or like this:

    =SUM(SUMIFS($D$4:$D$17,$B$4:$B$17,{"Class A","Class B"}))

    Hope this helps.

    Pete

  4. #4
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Sumifs give zero result

    If you're faced with a choice of summing everything APART from one criteria as here then

    Formula: copy to clipboard
    Please Login or Register  to view this content.

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

    Re: Sumifs give zero result

    "g7"
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    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".

  6. #6
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,427

    Re: Sumifs give zero result

    Or you can have this in G7:

    =G3+G4

    Hope this helps.

    Pete

  7. #7
    Forum Expert
    Join Date
    09-25-2015
    Location
    Milan Italy
    MS-Off Ver
    office 365
    Posts
    2,001

    Re: Sumifs give zero result

    G7=SUMPRODUCT(SUMIF(B4:B$17,F3:F4,D4:D17))

    another way

    G7=SUMPRODUCT((ISNUMBER(MATCH(B$4:B$17,F3:F4,0)))*(D4:D17))
    Last edited by CARACALLA; 09-16-2019 at 08:00 AM.

  8. #8
    Forum Contributor
    Join Date
    02-24-2015
    Location
    Egypt
    MS-Off Ver
    Office 365 ProPlus
    Posts
    774

    Re: Sumifs give zero result

    Thank you all for your solutions but I need to fix sumifs formula
    Note: I need one sumifs formula

  9. #9
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,427

    Re: Sumifs give zero result

    Quote Originally Posted by leprince2007 View Post
    ...Note: I need one sumifs formula...
    Why? Who dictates this constraint?

    Pete

  10. #10
    Forum Contributor
    Join Date
    02-24-2015
    Location
    Egypt
    MS-Off Ver
    Office 365 ProPlus
    Posts
    774

    Re: Sumifs give zero result

    Sorry Mr.Pete_UK but I need to use sumifs formula
    Why does it give zero?
    This is my question ,not to find another solution

  11. #11
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,427

    Re: Sumifs give zero result

    Richard told you what was wrong with your existing formula in Post #2. SUMIFS is using an AND condition in its criteria, so you were trying to SUM column D IF the cells in column B equal both F3 AND F4, which clearly cannot be the case.

    You want an OR condition, and you can achieve this by having two SUMIF terms added together. My two suggestions in Post #3 both show how this can be done.

    Hope this helps.

    Pete

  12. #12
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Sumifs give zero result

    ...and just to expand on Pete's post below, all criteria in a SUMIFS/COUNTIFS are mutually inclusive, and as more criteria are added you narrow down the number of results you'll get. As Pete says each criteria is an AND condition.

    You are looking at OR conditions. i.e. a result which includes BOTH F3 or F4, hence you need to add two SUMIFS each of which contains one or other of the F3 or F4 values.

  13. #13
    Forum Contributor
    Join Date
    02-24-2015
    Location
    Egypt
    MS-Off Ver
    Office 365 ProPlus
    Posts
    774

    Re: Sumifs give zero result

    Thanks a lot for your replies
    solved

  14. #14
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,427

    Re: Sumifs give zero result

    If that takes care of your original question, please take a moment to select Thread Tools from the menu above and to the right of your first post in this thread, and mark the thread as SOLVED.

    Also, you might like to know that you can directly thank those who have helped you by clicking on the small "star" icon located in the lower left corner of a post that you have found to be helpful (not just in this thread - for any post that has helped you). This also adds to the reputation of the poster (the small green bars in the poster's profile).

    Pete

+ 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] Ignore blank cell to give give non zero result
    By rehan0129 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 01-24-2018, 12:04 PM
  2. Replies: 2
    Last Post: 10-05-2017, 10:45 AM
  3. [SOLVED] If no SUMIFS matches, 1, otherwise the SUMIFS result...
    By JYTS in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 12-04-2016, 07:39 PM
  4. please help with compare two columns and give me result?
    By tomislav91 in forum Excel General
    Replies: 3
    Last Post: 01-24-2015, 02:48 PM
  5. SUMIFS Puzzle - Trying to avoid adding multiple SUMIFS to get valid result
    By haldavid in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 01-09-2013, 03:42 PM
  6. SUMIFS does not give a value for cell reference
    By inayat in forum Excel General
    Replies: 2
    Last Post: 09-23-2011, 03:02 AM
  7. seach and match to give result
    By prasjohn in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 12-14-2009, 06:19 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