How to build a summary table with PivotTable and PIVOTBY in Excel

Build the same sales summary two ways in Excel: a classic PivotTable and the newer PIVOTBY formula. You will see which one refreshes itself when your data changes and where slicers still win. It suits anyone comfortable with basic formulas who has Microsoft 365.

YouTube video: Are Pivot Tables Actually Dead? Let's Find Out

Caption availability is unknown. Check the CC control in the YouTube player.

7 chapters. Tap a step to jump to it.Chapters from the creator
Choose a chapter (7)
Video length
9 min 24 s
Time to do it
15 minutes
Difficulty
Medium
Steps
7

What you need

Steps

  1. Turn your source range into a table with Ctrl+T and confirm the header row has no blanks. Each column should hold one type of data, such as dates or amounts.

  2. Click any cell in the table and go to Insert, then PivotTable. Choose New Worksheet and click OK.

  3. Drag a category field such as Region into Rows, and a number field such as Sales into Values. Check that Values shows Sum, not Count.

  4. In an empty cell, type =PIVOTBY(row_fields, col_fields, values, SUM) using your actual ranges, for example =PIVOTBY(A2:A100,B2:B100,D2:D100,SUM). Press Enter and the whole summary spills at once.

  5. Add a new row to the source data. The PIVOTBY result updates instantly, while the PivotTable needs a right click and Refresh.

  6. To filter the PivotTable, click inside it, choose PivotTable Analyze then Insert Slicer, tick a field and click OK. Click a slicer button to filter.

  7. Feed the results into other formulas. Reference the spilled PIVOTBY range with the # operator, like =SUM(F2#), so the formula grows with the data.

Tips and common mistakes

PIVOTBY returns a #NAME? error on Excel 2019 and older, so check your version before building around it.

Slicers only attach to PivotTables, so keep a PivotTable if you need clickable filters.

Clean data matters more than the tool: remove blank rows and merge no cells before you start.

Refresh the PivotTable after any data change, or its totals will be out of date.

Questions

Can I use PIVOTBY in Excel 2019 or Excel 2021?

No. PIVOTBY is a dynamic array function that only works in Microsoft 365 builds, and older versions show a #NAME? error.

Can a slicer filter a PIVOTBY formula result?

No. Slicers connect to PivotTables only, so use a PivotTable when you want clickable filters or timelines.

Which one should I use for a quick summary?

Use PIVOTBY when you want a formula that refreshes itself. Use a PivotTable when you need slicers, grouping, or drill-down.

The notes are drafted automatically from video details and general task knowledge. How the guide was prepared

Report a correction

More in Money & Office

See all