How to Create an Excel PivotTable to Sum Sales by Product and Channel
Turn five transactions into a two-way sales report. Check the grand total, fix Count of Sales and refresh the report after a source value changes.
Follow these steps at your own pace. Check product terms and prices directly with providers before purchasing.
Quick answer
Click inside a clean sales list and choose Insert → PivotTable → From Table/Range. Place the report on a new worksheet. Drag Channel to Rows, Product to Columns and Sales to Values. Check that the field says Sum of Sales.
1. Enter one transaction per row
Copy the example below into A1:C6 on a blank sheet. Enter the amounts as numbers. The two Web orders for Mugs are intentional. They show whether Excel adds separate transactions into the same report cell. Keep totals outside the source rectangle. In E2 enter =SUM(C2:C6) and check for 100.
| Channel | Product | Sales |
|---|---|---|
| Web | Mugs | 15 |
| Store | Bags | 30 |
| Web | Mugs | 25 |
| Web | Bags | 10 |
| Store | Mugs | 20 |
2. Create the report on a new sheet
Select A1:C6. Go to Insert → PivotTable and choose From Table/Range if Excel offers a menu. Confirm that the source ends at C6, choose New Worksheet and click OK. Click inside the empty report if the PivotTable Fields pane is hidden. You can also open it from PivotTable Analyze → Field List.
3. Arrange the three fields
Drag Channel into Rows, Product into Columns and Sales into Values. Look where the Web row meets the Mugs column. That cell should show 40 from the two sales of 15 and 25. Store should have 20 for Mugs and 30 for Bags. Both channels should total 50, with a grand total of 100.
If the grand total is 5, you are counting transactions. Check the source amounts for numbers imported as text and correct them. Refresh the PivotTable. Open the menu beside Count of Sales under Values, choose Value Field Settings → Sum and click OK.
4. Test a change and refresh
Go back to the source sheet and change C2 from 15 to 18. Return to the report, right-click inside it and choose Refresh. The Web and Mugs intersection should now show 43. The grand total and the separate SUM in E2 should both read 103. This test catches a report that is pointing to the wrong source.
Will new rows appear when you refresh?
A fixed range ending at C6 may leave out a new row 7. Check PivotTable Analyze → Change Data Source and expand the range if needed. For a list that grows every week, turn the source into an Excel table and use that table as the source.
Microsoft Support · Create a PivotTable to analyze worksheet data
Comments
Read or join the discussion.