+ Reply to Thread
Results 1 to 14 of 14

SUMIF: searching multiple columns for criteria

  1. #1
    Registered User
    Join Date
    10-12-2021
    Location
    Bristol
    MS-Off Ver
    365
    Posts
    27

    Red face SUMIF: searching multiple columns for criteria

    Hi All,

    I currently have the following formula SUMIF(G4:G434,U10,L4:L434) i also need to search column J as well as column L for the criteria. Any suggestions.

    Thanks
    Last edited by AliGW; 10-12-2021 at 09:54 AM. Reason: Title changed - please think more carefully about your thread titles in future!

  2. #2
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,623

    Re: SUMIF: searching multiple columns for criteria

    Administrative Note:

    Welcome to the forum.

    We would very much like to help you with your query, however the thread title does not really convey what your request is about. Tell us what you are trying to do, not how you think it should be done.

    Please take a moment to amend your thread title. Make sure that the title properly explains your request. Your title should be explicit and not be generic (this includes function names used without an indication of what you are trying to achieve).

    Please see Forum Rule #1 about proper thread titles and adjust accordingly. To edit the thread title, open the original post to edit and then click on Go Advanced (bottom right) to access the area where you can edit your title.

    (Note: this change is not optional. As you are new here, I have done it for you as a courtesy this time.)
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,623

    Re: SUMIF: searching multiple columns for criteria

    You can't do an OR search directly with SUMIF or SUMIFS.

    There are instructions at the top of the page explaining how to attach your sample workbook.

  4. #4
    Forum Expert
    Join Date
    09-25-2015
    Location
    Milan Italy
    MS-Off Ver
    office 365
    Posts
    1,781

    Re: SUMIF: searching multiple columns for criteria

    Post a small Excel sheet (not a picture) showing realistic & representative sample data WITHOUT confidential information (10-20 rows, not thousands...) and some manually calculated results. For a new thread (1st post), scroll to Manage Attachments, otherwise scroll down to GO ADVANCED, click, and then scroll down to MANAGE ATTACHMENTS and click again. Now follow the instructions at the top of that screen.

  5. #5
    Registered User
    Join Date
    10-12-2021
    Location
    Bristol
    MS-Off Ver
    365
    Posts
    27

    Re: SUMIF: searching multiple columns for criteria

    Thank you - Most appreciated.

  6. #6
    Registered User
    Join Date
    10-12-2021
    Location
    Bristol
    MS-Off Ver
    365
    Posts
    27

    Re: SUMIF: searching multiple columns for criteria

    Attached sample.

    I need to also include column E criteria in the results in column H.
    Attached Files Attached Files

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

    Re: SUMIF: searching multiple columns for criteria

    H5=IF($G5<>"",SUMPRODUCT(($B$5:$B$17=$G5)*($C$5:$E$17)),"")


    Copy down

  8. #8
    Forum Expert wk9128's Avatar
    Join Date
    08-15-2020
    Location
    Taiwan
    MS-Off Ver
    365 V2403 and WPS V2022
    Posts
    3,397

    Re: SUMIF: searching multiple columns for criteria

    Cell H5 formula , Drag down

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

  9. #9
    Registered User
    Join Date
    10-12-2021
    Location
    Bristol
    MS-Off Ver
    365
    Posts
    27

    Re: SUMIF: searching multiple columns for criteria

    AHHHH - just noticed I have a column D in my spreadsheet. Can $C$5:$E$17 be or and not all inclusive.

  10. #10
    Forum Expert wk9128's Avatar
    Join Date
    08-15-2020
    Location
    Taiwan
    MS-Off Ver
    365 V2403 and WPS V2022
    Posts
    3,397

    Re: SUMIF: searching multiple columns for criteria

    Hi @catley666 My formula does not contain D, only columns C and E

  11. #11
    Registered User
    Join Date
    10-12-2021
    Location
    Bristol
    MS-Off Ver
    365
    Posts
    27

    Re: SUMIF: searching multiple columns for criteria

    Its working perfect - thank you for the help

  12. #12
    Forum Expert
    Join Date
    09-25-2015
    Location
    Milan Italy
    MS-Off Ver
    office 365
    Posts
    1,781

    Re: SUMIF: searching multiple columns for criteria

    H5=if($g5<>"",sumproduct(($b$5:$b$17=g5)*(($c$5:$c$17)+($e$5:$e$17))),"")

  13. #13
    Forum Expert wk9128's Avatar
    Join Date
    08-15-2020
    Location
    Taiwan
    MS-Off Ver
    365 V2403 and WPS V2022
    Posts
    3,397

    Re: SUMIF: searching multiple columns for criteria

    @CARACALLA your formula Minor modification

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

  14. #14
    Forum Expert wk9128's Avatar
    Join Date
    08-15-2020
    Location
    Taiwan
    MS-Off Ver
    365 V2403 and WPS V2022
    Posts
    3,397

    Re: SUMIF: searching multiple columns for criteria

    @catley666 You're Welcome. Glad to help . Thank You for the feedback


    If you finally get a solution please mark your thread as SOLVED:
    - Click Thread Tools above your first post, select "Mark your thread as Solved".
    - Please click on the *Add Reputation button at the bottom left.

+ 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