+ Reply to Thread
Results 1 to 2 of 2

Excel Pivot to summarize by category all rows based at least one row containing criteria

  1. #1
    Registered User
    Join Date
    05-17-2016
    Location
    Cincinnati, Ohio
    MS-Off Ver
    Microsoft 365 Enterprise Version 2208 Build 15601.20680
    Posts
    3

    Excel Pivot to summarize by category all rows based at least one row containing criteria

    I'm trying to figure out out to make a pivot table to sum all rows by category when one at least one of the rows contains a specific value. In the attached example, I want to sum the cost for all rows by category but only if there is at least one row containing type car. Both the New and Sold Categories have 1 or more rows with a car so I want those summed. The used category does not contain any cars so I don't want those included. The pivot table should result with New = $51,000 and Sold = $50,000 for a grand total of $101,000.
    Attached Files Attached Files

  2. #2
    Forum Expert Roel Jongman's Avatar
    Join Date
    03-28-2015
    Location
    Netherlands
    MS-Off Ver
    Office 365
    Posts
    1,483

    Re: Excel Pivot to summarize by category all rows based at least one row containing criter

    I think the only way to solve this is to have a help column.
    I named it Category has Car. That uses the formula, that will have TRUE or FALSE as result
    Please Login or Register  to view this content.
    Then you can create a pivot table with the helper column as filter set to TRUE
    and Catecory in the row area and cost in the values area
    (see attached file)


    __________________
    since you use Microsoft 365 I also added a bonus answer using the new dynamic array functions and parameters.

    I used the Unique() and Filter funtions to spill all categories with a Car
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    and I used a SUMIFS. this function will spill based on found results because I added the # after the cellreference to ($H19#)
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    If you add a line that has category Used and type car you will see that the category and sumamount is added below Sold instantly.
    Attached Files Attached Files

+ 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. Summarize smallest rows in a Pivot Table
    By BrettW in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 02-24-2020, 04:55 PM
  2. Summarize Based on Multiple Criteria
    By Kumara_faith in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 06-28-2015, 10:23 AM
  3. Changing a pivot chart column color based on the pivot table category
    By Shawne in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 10-08-2014, 09:12 AM
  4. [SOLVED] Power Pivot Summarize Value By Category From Total
    By goss in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 04-24-2014, 05:52 AM
  5. [SOLVED] summarize information based on criteria using excel
    By zhengzhi8806 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-03-2013, 11:42 AM
  6. [SOLVED] Summarize Based on Criteria
    By Kumara_faith in forum Excel General
    Replies: 6
    Last Post: 07-24-2013, 10:39 AM
  7. [SOLVED] How to summarize daily schedule by value and category?
    By briancox22 in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 02-22-2013, 11:41 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