Welcome to Module 3 of Pivot Tables in Excel! In the previous module, we learned how to prepare data before analysing it. Now, we are going to create our first PivotTable.
By the end of this lesson, you will know how to select your data, insert a PivotTable, arrange fields and use it to summarise information.
A PivotTable is an Excel feature that helps you summarise a large amount of information quickly.
Imagine you own a supermarket in Ibadan. Every day, customers buy different products such as rice, beans, milk, bread and cooking oil.
After one month, you may have hundreds or thousands of sales records. Instead of counting everything manually, you can use a PivotTable to answer questions such as:
A PivotTable helps you find these answers without writing complicated formulas.
Before creating a PivotTable, make sure you have a properly organised dataset.
Your data should have:
For example, consider this supermarket sales dataset:
| Date | Product | Branch | Quantity | Sales (โฆ) |
|---|---|---|---|---|
| 01/11/2026 | Rice | Ibadan | 5 | 50,000 |
| 02/11/2026 | Beans | Lagos | 3 | 24,000 |
| 03/11/2026 | Rice | Lagos | 2 | 20,000 |
| 04/11/2026 | Milk | Ibadan | 4 | 12,000 |
| 05/11/2026 | Beans | Ibadan | 2 | 16,000 |
This small dataset will help us understand how a PivotTable works.
First, open Microsoft Excel and load the workbook containing your sales records.
Check that your data is arranged correctly before continuing.
You need to select the information you want Excel to analyse.
Do not select only the sales column. A PivotTable needs the other columns too if you want to analyse sales by product, branch or date.
Now, let's create the PivotTable.
Excel will create a new worksheet with an empty PivotTable area and a PivotTable Fields panel.
Choosing New Worksheet keeps your original sales records separate from your PivotTable report. It is a good choice when you are learning.
The PivotTable Fields panel displays the headings from your original dataset.
For our supermarket example, the fields are:
Below the field names, you will normally see four important areas.
The Filters area allows you to filter the entire PivotTable report using a selected field.
For example, you can use Branch as a filter to view sales from only the Ibadan branch.
The Columns area displays selected information across the top of the PivotTable.
For example, you can place Branch in Columns to compare different branches side by side.
The Rows area displays information down the side of the PivotTable.
For example, placing Product in Rows will list Rice, Beans, Milk and other products vertically.
The Values area performs calculations on your data.
For example, placing Sales in Values will usually calculate the total sales amount.
| Area | Purpose | Example |
|---|---|---|
| Filters | Filters the report | Branch |
| Columns | Displays categories across the top | Branch |
| Rows | Displays categories down the side | Product |
| Values | Calculates numbers | Sales |
Let's find out how much money the supermarket made from each product.
Follow these steps:
Excel should display each product and its total sales amount.
Using our sample records, the result should look like this:
| Product | Total Sales (โฆ) |
|---|---|
| Beans | 40,000 |
| Milk | 12,000 |
| Rice | 70,000 |
| Grand Total | 122,000 |
Great! You have created your first PivotTable. It has calculated the total sales for each product automatically.
Now, let's compare sales between the Ibadan and Lagos branches.
Your PivotTable will show the sales for each product under the different branches.
Using our sample records, the summary will look like this:
| Product | Ibadan (โฆ) | Lagos (โฆ) | Total (โฆ) |
|---|---|---|---|
| Rice | 50,000 | 20,000 | 70,000 |
| Beans | 16,000 | 24,000 | 40,000 |
| Milk | 12,000 | 0 | 12,000 |
| Grand Total | 78,000 | 44,000 | 122,000 |
From this report, we can see that the Ibadan branch recorded โฆ78,000 in sales, while the Lagos branch recorded โฆ44,000.
You can use the Filters area to control what information appears in your report.
For example, let's filter the report by branch.
Your PivotTable will now show information for the selected branch. You can change the filter whenever you want.
Imagine you add a new sales record to your original dataset. Will your PivotTable automatically show the new information?
Usually, you need to refresh the PivotTable so that it reads the updated source data.
You can also look for the Refresh command under the PivotTable Analyse tab in supported desktop versions of Excel.
If your PivotTable uses an Excel Table as its source, newly added rows are generally included when you refresh it. If your source is an ordinary fixed range, you may need to expand the source range first.
| Mistake | How to Fix It |
|---|---|
| Missing column headings | Give every column a clear heading. |
| Putting Sales in Rows instead of Values | Drag Sales into the Values area when you want to calculate totals. |
| Using the wrong data range | Check that all relevant records and headings are included. |
| Forgetting to refresh | Refresh after changing the source data. |
| Numbers stored as text | Check and correct the original data before analysing it. |
It is time to practise what you have learned.
Imagine you are helping a supermarket manager in Ibadan. The manager wants to know which products sell the most and which branch generates more sales.
Your task:
Can you create a PivotTable that shows the total quantity of products sold by each branch? Try using Quantity in the Values area instead of Sales.
Answer the following questions to check your understanding.
What is a PivotTable used for in Excel?
A. Playing music
B. Summarising and analysing data
C. Designing websites
D. Sending emails
Which Excel tab is commonly used to insert a PivotTable?
A. Review
B. View
C. Insert
D. Page Layout
Which area displays categories vertically in a PivotTable?
A. Rows
B. Values
C. Filters
D. Columns
Which area is used to calculate the total sales amount?
A. Filters
B. Rows
C. Columns
D. Values
What happens when you place Product in the Rows area?
A. Excel deletes the products
B. Products are listed vertically
C. Excel closes the workbook
D. Products become pictures
Which area can be used to filter a report by branch?
A. Values
B. Rows
C. Filters
D. Columns
What should you do after adding new records to your source data?
A. Refresh the PivotTable
B. Delete the workbook
C. Remove all headings
D. Close Excel permanently
What does Grand Total represent?
A. The first product in the list
B. The name of the worksheet
C. The total number of columns
D. The overall calculated total
Which field would you place in Values to calculate the total number of items sold?
A. Product
B. Quantity
C. Branch
D. Date
Where can Excel place a newly created PivotTable?
A. Only inside a chart
B. Only in a different workbook
C. In a new or existing worksheet
D. Only in Microsoft Word
| Question | Correct Answer |
|---|---|
| 1 | B |
| 2 | C |
| 3 | A |
| 4 | D |
| 5 | B |
| 6 | C |
| 7 | A |
| 8 | D |
| 9 | B |
| 10 | C |
Well done! You have completed Module 3.
In this module, you learned how to create your first PivotTable, select your dataset, arrange fields into Rows, Columns, Values and Filters, summarise sales information and refresh your report.
You can now use Excel to turn ordinary sales records into useful reports without manually calculating every figure.
Understanding PivotTable Fields and Layout
In the next module, we will explore PivotTable fields in greater detail and learn how to change the layout of reports to make information easier to understand.