+ Reply to Thread
Results 1 to 8 of 8

Sum multiple columns and using wildcards

  1. #1
    Registered User
    Join Date
    01-10-2013
    Location
    usa
    MS-Off Ver
    Excel 2007
    Posts
    24

    Sum multiple columns and using wildcards

    Would like to sum multiple columns for all the rows which includes certain characters, for example in the attached spreadsheet I want to total column Jan and Feb for all fruit which which ends with "berry",
    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: Sum multiple columns and using wildcards

    Hi

    =SUMIFS(B3:B7,A3:A7,"*berry")

    change for B3:B7 for other months
    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
    Registered User
    Join Date
    01-10-2013
    Location
    usa
    MS-Off Ver
    Excel 2007
    Posts
    24

    Re: Sum multiple columns and using wildcards

    Thanks Richard, but I would need the total for both months together.

  4. #4
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,620

    Re: Sum multiple columns and using wildcards

    =SUMPRODUCT(--ISNUMBER(SEARCH("*berry",A3:A7))*B3:C7)
    Ben Van Johnson

  5. #5
    Registered User
    Join Date
    01-10-2013
    Location
    usa
    MS-Off Ver
    Excel 2007
    Posts
    24

    Re: Sum multiple columns and using wildcards

    Thanks Ben, it works, but what if I have 3 months, Jan, Feb & Mar and I only want to calculate the *berry for the months of Jan and Mar, excluding Feb?

  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,253

    Re: Sum multiple columns and using wildcards

    assuming Mar is in column D

    =SUM(SUMPRODUCT(--ISNUMBER(SEARCH("*berry",A3:A7))*((B2:D2="Jan") +(B2:D2="Mar")) *B3:D7))

  7. #7
    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: Sum multiple columns and using wildcards

    ....why not put your data into a format that can be used by a Pivot Table driven by a Slicer or two. You'll then have a far more flexible analysis tool and won't need any formulae

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

    Re: Sum multiple columns and using wildcards

    Formula

    HTML Code: 

+ 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. Multiple Wildcards in VLOOKUP
    By Lumberman11 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 12-14-2020, 05:54 PM
  2. [SOLVED] Using wildcards to search multiple sheets
    By dave57 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 05-30-2017, 01:34 PM
  3. [SOLVED] Counting multiple wildcards
    By gz3s36 in forum Excel General
    Replies: 7
    Last Post: 12-12-2016, 05:31 PM
  4. Vba if then statement with multiple cases and wildcards
    By LightKerosene in forum Excel Programming / VBA / Macros
    Replies: 13
    Last Post: 09-28-2015, 12:17 PM
  5. Coloring rows based on values in columns (+ wildcards)
    By astrbac in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 05-08-2014, 09:23 AM
  6. Search and retrieve information from columns in Excel into list view (wildcards VBA)
    By martinl4 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-11-2011, 07:58 AM
  7. VLOOKUPS, wildcards, and multiple columns of source data
    By Cabby in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-10-2008, 06:49 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