Create Relationships Between Excel Tables for Power Pivot
Question details
Create a relationship between Excel tables so their fields can be used together in a Power Pivot PivotTable.

- Product
- Microsoft Excel Power Pivot
- Device & OS
- not provided
- Scenario
- The user wants to connect a lookup table and a transaction table in an Excel data model.
- Observed behavior
- Duplicate or mismatched keys, or a missing relationship, can cause repeated PivotTable values or prompts to create a relationship.
Identify the column shared by the tables and check that its data type matches in both tables. The lookup-side key must contain unique values; resolve duplicate, blank, or mismatched keys before creating the relationship.
Create a one-to-many relationship in the Excel data model
Use this method to connect a unique lookup key to matching keys in a transaction table for a PivotTable.
A Power Query connection imports or transforms data; it is not itself a relationship between tables in the Power Pivot data model.
Select each Excel table and choose Power Pivot > Add to Data Model. If you use Power Query, load each query with the option to add it to the Data Model.
In the lookup table, review the key column and use Data > Remove Duplicates if duplicate rows are not needed. Correct blank or mismatched keys and make sure the corresponding columns use matching data types.
Choose Data > Relationships > New. Alternatively, open Power Pivot > Manage and use Diagram View to connect the columns.
In the Create Relationship dialog, select the transaction table and its key as the table and column. Select the lookup table and its unique key as the related table and related column, then click OK.
Choose Insert > PivotTable and select the workbook's Data Model as the source. Add fields from both tables and check that values change appropriately across the lookup categories; use PivotTable Analyze > Refresh if needed.

Work with spreadsheets in WPS Office
WPS Office is a free, lightweight alternative with a familiar interface and Microsoft Office format compatibility, making it easy to move everyday spreadsheet work between suites. It does not repair Excel Power Pivot data-model relationships.

Frequently Asked Questions
Is a Power Query connection the same as a Power Pivot relationship?
No. Power Query imports and transforms data, while a data-model relationship connects columns in different tables. Create or inspect relationships under Data > Relationships or in Power Pivot Diagram View.
Which column needs unique values?
The related lookup table's key must be unique. The transaction table's matching key can appear in many rows. Check the lookup column for duplicates before selecting it as the related column in Data > Relationships.
Why does my PivotTable show the same total for every category?
The tables may not have a valid relationship, or the PivotTable may not be using the Data Model. Check Data > Relationships, confirm the keys match, and verify the PivotTable's data source.
What if I cannot see the Power Pivot tab?
In supported Excel installations, check File > Options > Add-ins, select COM Add-ins in the Manage box, and click Go to enable Microsoft Power Pivot for Excel. Availability depends on your Excel version and installation.




