+ Reply to Thread
Results 1 to 6 of 6

Sumif

  1. #1
    Registered User
    Join Date
    05-09-2013
    Location
    Hampshire
    MS-Off Ver
    Excel 2019
    Posts
    38

    Sumif

    Hi,

    Please would you mind advising on the correct formula for the attached please? I just want to bring back the total of 2 cols based on a department criteria. I can't get my sum if to work...

    Many thanks

    Suzanne
    Attached Files Attached Files

  2. #2
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,167

    Re: Sumif

    Hi Suzanne,

    Try this and pull down,

    =SUMIF($B$1:$B$22,B27,C1:C22)+SUMIF($B$1:$B$22,B27,D1:D22)
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

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

    Re: Sumif

    You can put this formula in cell E27:

    =SUMIF($B$2:$B$22,B27,$C$2:$C$22)+SUMIF($B$2:$B$22,B27,$D$2:$D$22)

    then copy down.

    An alternative is to use this array* formula:

    =SUM(IF($B$2:$B$22=B27,$C$2:$C$22+$D$2:$D$22))

    and copy that down.

    *Note that an array formula needs to be committed using the key combination of Ctrl-Shift-Enter (CSE) instead of the usual < Enter >.

    Hope this helps.

    Pete

  4. #4
    Registered User
    Join Date
    05-09-2013
    Location
    Hampshire
    MS-Off Ver
    Excel 2019
    Posts
    38

    Re: Sumif

    Thanks Marvin - that's great.

  5. #5
    Registered User
    Join Date
    05-09-2013
    Location
    Hampshire
    MS-Off Ver
    Excel 2019
    Posts
    38

    Re: Sumif

    Thank you Pete - that's great. I'll definitely be making use of the array formula in the future!

  6. #6
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,147

    Re: Sumif

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

+ 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. SumIf formula or Sumif with pivottable combined question
    By mcgleeuw in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-10-2015, 01:05 PM
  2. Replies: 4
    Last Post: 12-04-2014, 02:06 PM
  3. Subtracting from the SUMIF with the difference from the SUMIF range
    By iamblue91 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 09-04-2014, 09:01 PM
  4. [SOLVED] Shorten SUMIF + SUMIF + SUMIF each with same reference range but different criteria???
    By HeyInKy in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 04-13-2014, 09:25 PM
  5. SUMIF or SUMIF's formula with multiple criteria
    By jackiemariee in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 09-30-2013, 06:19 PM
  6. Nested SUMIF statement or multiple SUMIF's
    By Dan27 in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 09-17-2009, 06:55 AM
  7. [SOLVED] nested sumif or sumif with two criteria
    By dshigley in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 04-04-2005, 11:06 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