Concatenating fields in a Pivot Table merges text values (like names, codes, or descriptive labels) to display complete strings across rows or columns. Without it, you might see partial names like "Smith" instead of "SmithJohnson" in customer data summaries. This works best when you have a consistent delimiter (like a comma or space) to separate values—but Excel’s built-in tools don’t support dynamic concatenation directly. Instead, you’ll combine Pivot Table measures with calculated fields or use Power Query to pre-format your source data.

What You'll Need

  • A Pivot Table created from a data source (Excel table, Query, or database) where you have text fields that need merging.
  • A clear understanding of which fields contain the text you want to join (e.g., "FirstName" and "LastName" for full names).
  • Excel’s CONCAT() function (introduced in Excel 365/2021) or older methods like TEXTJOIN() or manual concatenation via formulas.
  • Optional: A helper column in your source data if the Pivot Table doesn’t support direct concatenation (e.g., for reporting purposes).

Step-by-Step

  1. Prepare Your Data Source
    1. Ensure your data is structured in an Excel table (Ctrl+T) or Query. Columns for text fields (e.g., "CustomerName") should not contain spaces or special characters that could break concatenation.
    2. If concatenating multiple fields (e.g., "FirstName" + "LastName"), create a temporary column in your source table to hold the merged text. Format this column as plain text (right-click > Format Cells > Text). For example:
      
              FirstName    LastName    FullName
              John         Doe        John Doe
              
  2. Create the Pivot Table
    1. Paste your data range into Excel, then go to Insert > PivotTable. Place the full-name column in the Values area (this will show the merged text in the Pivot Table).
    2. Drag the original fields (e.g., "CustomerName") into the Rows or Columns area—these will now appear as separate rows/columns, not merged.
      1. If you want to see the full name alongside other metrics (e.g., total sales), add the full-name column to the Values area and configure the Pivot Table to show counts, sums, or averages.
  3. Use a Calculated Field for Dynamic Concatenation (Excel 365/2021)
    1. Right-click the Pivot Table > Fields > New Calculate Field.
    2. Name it (e.g., "Full Name") and use the formula:
      CONCAT([FirstName], " ", [LastName])
    3. Click OK. The new field appears under the Pivot Table’s Fields list.
    4. Drag this new field to the Rows or Columns area. The Pivot Table now displays merged names.
      1. Note: If using older Excel (2019 or earlier), replace CONCAT() with TEXTJOIN(", ", TRUE, [FirstName], [LastName]) to separate values with spaces.
  4. Alternative: Pre-Concatenate in Power Query
    1. Go to Data > Get Data > From Table/Range and load your data into Power Query.
    2. Right-click the "FullName" column (if not created) > Add Column > Custom Column. Enter:
      = Text.Combine([FirstName], " ")
    3. Click OK, then close & load the data back to Excel.
    4. Create the Pivot Table from this modified data—now the full names are pre-formatted.
  5. Format the Pivot Table for Readability
    1. Right-click the merged text column > Format Values.
    2. Set the font weight to Bold or alignment to Center for clarity.
      1. For reports: Add a helper column in your source data (e.g., "ReportFullName") that concatenates fields with a comma or pipe (|) for readability, then reference this column in the Pivot Table.

Common Mistakes

  • Missing Delimiters: If fields contain hidden spaces (e.g., "Smith \n Johnson"), use TEXTJOIN() with TRUE to ignore blanks: TEXTJOIN(", ", TRUE, [FirstName], [LastName]). Alternatively, clean data before concatenation.
  • Pivot Table Ignores Formatted Columns: Text-formatted columns (e.g., "FirstName" with Text alignment) won’t concatenate cleanly. Create a plain-text column in your source data instead.
  • Empty Values Breaking Formulas: Wrap fields in IFERROR() to avoid errors:
    = IFERROR(CONCAT([FirstName], " ", [LastName]), "")
  • Case Sensitivity: Use UPPER(), LOWER(), or TRIM() to standardize text (e.g., CONCAT(LOWER([FirstName]), " ") ).

Tips

  • For Large Datasets: Use Power Query to pre-filter and concatenate data before creating the Pivot Table. This avoids recalculating for each change.
  • Comma as Delimiter: If you must use commas (e.g., for CSV exports), replace spaces with commas in the formula:
    = CONCATW(",", [FirstName], [LastName])
  • Test with Sample Data: Create a small dataset first to verify the concatenation works before applying it to your full report.
  • Dynamic Concatenation: For fields that change (e.g., "LastName" updates monthly), use Power Query or a VBA macro to rebuild the concatenated column automatically.
  • Pivot Table Memos: Right-click the merged column > Memos to add a tooltip showing the original fields (e.g., "John Doe" = FirstName + LastName).

Troubleshooting

  1. Concatenation Shows Blank Values:
    1. Check if fields are blank or formatted as numbers/dates. Right-click the Pivot Table > Field Settings > ensure the merged column is set to Show Values As: Numbers (default for concatenation).
    2. Verify no formatting (e.g., currency symbols) is hiding values. Select the merged column > Format Number > choose Plain.
  2. Pivot Table Doesn’t Update:
    1. Right-click the Pivot Table > Refresh to recalculate.
    2. Ensure the data source refreshes automatically (check Data > Refresh All if using Queries).
  3. Formula Errors (e.g., "#VALUE!"):
    1. Check for hidden formulas or macros in your source data. Enable macros temporarily to test.
    2. Use a helper column with plain text format to isolate the issue.
  4. Pivot Table Appears Empty:
    1. Ensure the merged column is in the Values area. Drag it there directly from the Fields list.
    2. Filter the Pivot Table to include all rows (e.g., use the "Show All Data" filter).
  5. Concatenation Doesn’t Match Source Data:
    1. Compare the merged column in Excel with the original data. Look for hidden characters (e.g., tabs, line breaks) or formatting issues.
    2. Use the Find & Select (Ctrl+F) feature to search for mismatched values in your source data.

Frequently Asked Questions

How do I concatenate two columns in a Pivot Table without using Excel 365?

Use TEXTJOIN() in a calculated field: = TEXTJOIN(" ", TRUE, [FirstName], [LastName]) This joins values with spaces, ignoring blank rows. For commas, use TEXTJOIN(",", TRUE, ...).

Can I concatenate columns that contain dates or numbers?

No—concatenation only works with text. First convert dates/numbers to text using TEXT([DateColumn], "YYYY-MM-DD") or TEXT([NumberColumn], "0") before joining.

My Pivot Table shows "Error" when concatenating. What’s wrong?

The error likely comes from blank values or formatted columns. Wrap the formula in IFERROR() or ensure both fields are plain-text columns. Test with a simple formula like CONCAT([A1], " ") first.

How do I concatenate fields with different lengths (e.g., "John" vs "John Doe")?

Use RIGHT() or LEFT() to pad shorter strings with spaces: = CONCAT([FirstName], " ", IF(LEN([LastName])>0, RIGHT(" ", 10-LEN([FirstName])), ""), [LastName]) This adds 10 spaces to the name if it’s too short.

Can I concatenate fields across multiple sheets?

Yes, but first merge the data into a single sheet or use Power Query to combine sheets before concatenating. In Excel, drag the merged column into the Pivot Table as usual.

What’s the fastest way to concatenate a long list of fields?

Use Power Query to build a single column with Text.Combine(), then load this into Excel and create the Pivot Table. This avoids recalculating for each change.