PivotTable Aggregating Incorrect Data

Written by Allen Wyatt (last updated May 14, 2022)
This tip applies to Excel 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021


Liesie has a PivotTable that she's been working with for some time. It is suddenly and unexpectedly pulling the wrong info from the source data. Out of 16 unique identifiers, NR22229 and NR22447 are pulling through as NR21219 and NR21447, while all the rest are correct! Liesie has checked and there is not an incorrect entry in the PivotTable data source range. She wonders what would cause the PivotTable to do this and if there is a way to correct it.

These types of issues are notoriously difficult to troubleshoot without actually working with the workbook. Even so, a few things can be suggested to fix the problem. Assuming that the identifiers are being shown in rows, it is possible that there was an inadvertent typeover of the two Row Labels (NR22229 and NR22447) in the PivotTable. The typeover would result in the data being pulled from the wrong location—whatever was typed into the Row Label area becomes the new label for that value.

If you suspect this is the issue, you can remove the identifiers field from the Field area, and then refresh the PivotTable. (Refreshing is important as it forces a renewed fetching of the data to be aggregated in the PivotTable.) You can then place the identifiers field back into the PivotTable.

If that doesn't fix the issue, then it could be that Excel is still confused on how to pull the proper data into the PivotTable. This can be especially true if you have deleted data, columns, or rows in the source data. To fix this potential issue, follow these general steps:

  1. Right-click a cell within the problem PivotTable. Excel displays a list of options.
  2. Choose PivotTable Options. Excel displays the PivotTable Options dialog box.
  3. Make sure the Data tab is displayed. (See Figure 1.)
  4. Figure 1. The Data tab of the PivotTable Options dialog box.

  5. Using the Number of Items to Retain Per Field drop-down list, choose the None option.
  6. Click OK.
  7. Refresh the PivotTable.

If that still does not work, then the remaining (and most drastic) solution is to delete the PivotTable and recreate it from your source data.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (12882) applies to Microsoft Excel 2007, 2010, 2013, 2016, 2019, Excel in Microsoft 365, and 2021.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Removing a Trendline Error Message

Excel allows you to add trendlines to your charted data. It is possible, though, that lately you've been seeing a ...

Discover More

Referencing Fields in Another Document

Sometimes you may have two documents that are so integrally related to each other that the one document may require the ...

Discover More

Using a Formula to Replace Spaces with Dashes

If you need a formula to change spaces to some other character, the SUBSTITUTE function fits the bill. Here's how to use it.

Discover More

Professional Development Guidance! Four world-class developers offer start-to-finish guidance for building powerful, robust, and secure applications with Excel. The authors show how to consistently make the right design decisions and make the most of Excel's powerful features. Check out Professional Excel Development today!

More ExcelTips (ribbon)

Error in Linked PivotTable Value

Excel allows you to link to values in other workbooks, even if those values are in PivotTables. However, Excel may ...

Discover More

Expanding PivotTable Rows to Sheets

PivotTables are a great way to work with large quantities of data in an intelligent manner. Sometimes, however, you just ...

Discover More

Easy Filtering Specifications for a PivotTable

When you want to include specific records from a source table into a PivotTable, you need to employ some sort of ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is one less than 9?

There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)


This Site

Got a version of Excel that uses the ribbon interface (Excel 2007 or later)? This site is for you! If you use an earlier version of Excel, visit our ExcelTips site focusing on the menu interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.