Home > Pivot > Layout > Grouping

Pivot Table Grouping Error Cannot Group That Selection

Debra Dalgleish - Contextures

See how to fix the pivot table grouping error, "Cannot group that selection"and common causes for this pivot table error.

pivot error Cannot group that selection

Table of Contents

1) Video: Cannot Group that Selection

In this short video, I show two examples for the "Cannot group that selection" pivot table error message. There are details for all 3 common causes below the video.

2) Error: Cannot Group That Selection

If you try to group a date or number field, you may see an Excel error message, with a yellow warning label, that says, "Cannot group that selection."

pivot error Cannot group that selection

3) Common Causes - Cannot Group That Selection

There are 3 common causes for this pivot table grouping error message:

  1. Pivot table was added to Data Model
  2. Data source has some blank cells
  3. Previously grouped items still in field list

See the details on these causes, and steps to fix them, in the sections below.

4) Cause A: Pivot Table - Data Model

When you created the pivot table, did you check the box to "Add this data to the Data Model"?

If so, you won't be able to group any pivot items.

check box Add this data to the Data Model

4.1) Different Type of Pivot Table

When the Data Model option is checked:

  • Excel does not create a normal pivot table.
  • Instead, Excel creates an OLAP-based Power Pivot
    • In OLAP-based pivot tables, the grouping feature is not available.

4.2) Fix Problem A - 2 Workarounds

In the following sections, there are two workarounds to fix this problem:

-- Fix A1: Create a normal pivot table (not in the Data Model)

-- Fix A2: Add a Group column in the souce data

4.2.1) Fix A1: Normal Pivot Table

If you need to group the data, create another pivot table, based on the same data.

When setting up the new pivot table, do NOT check the "Add this data to the Data Model" option

check box Add this data to the Data Model

4.2.2) Fix A2: New Column

Another workaround is to add a new "Group" column in the source data.

In the Group column:

  1. Type a grouping category for each item
    • OR
  2. Use a lookup formula and lookup table, to calculate the grouping category.

Then, refresh the pivot table, and add the "Group" field to the pivot table layout.

4.2.3) New Column Example

In the screen shot below, an XLOOKUP formula finds the Category name in the lookup table (tblCat), and returns the Group name.

  • =XLOOKUP([@Category], tblCat[Category], tblCat[Group],"",0)

xlookup formula to return group name

  • Refresh the pivot table, so the new field appears in the field list.
  • Then, add the Group field to the pivot table, and remove the Category field.

group field in pivot table to replace date field

5) Cause B: Blank Cells or Text

In a normal pivot table, you might get an unexpected error when you try to group dates or numbers.

  • This grouping error is usually caused by blank cells, or text entries, where Excel expects dates or numbers

For example, in the screen shot below, I right-clicked a date cell, then clicked Group. The error message appeared: "Cannot group that selection."

Excel error when trying to group dates in pivot table

In the source data, there are 3 dates that are left-aligned, unlike the other numbers. When I selected 5 date cells, the status bar showed that:

  • only 2 cells have real numbers
  • the other 3 are text values, that look like numbers.

That's why Excel can't group the dates in the pivot table.

3 cells are text values, that look like numbers

5.1) Fix Problem B

To fix the problem with blanks or text:

  • For blank cells, fill in the date/number (use a dummy date/number if necessary).
  • If there is text in the date/number field, remove it.
  • If numbers are being recognized as text, use one of the techniques to change text to real numbers. Then return to this pivot table tutorial, and try the grouping steps.

6) Cause C: Previous Grouping

Another possible cause for the grouping error is a grouped field left over from the previous time that you grouped the data.

  • This doesn't happen too often, but it's something to check!

6.1: Fix Problem C

To fix the problem, if previous grouping is the cause, follow these steps:

  1. Check the pivot table field list, to see if there's a second copy of the date field, e.g. Date2.
  2. If there is, add that field to the pivot table layout, in the row area, and ungroup it.
  3. After that, you should be able to group the date field again. go to top

7) Get the Sample Files

Get Monthly Excel Tips!

Be sure to get my monthly newsletter, with quick Excel tips, links, news, and a bit of fun. Just add your email, then click Sign Up.

More Tutorials

Pivot Grouping: Pivot table grouping examples. Group Excel pivot table dates, numbers, or text.

Old Items: If pivot table drop downs show outdated items, see the steps to clear old items in Pivot Table, and prevent them from reappearing.

Calculated Item: Videos and written steps show how to create a calculated item in an Excel pivot table. See the features, restrictions, warnings.


Last updated: November 14, 2026 3:20 PM