Inside The Web
    Facebook Twitter Instagram
    Inside The Web
    • Office
      • Excel
      • Ms Word
      • OneDrive
      • Google Docs
      • Google Sheets
      • Google Drive
    • Email
      • Gmail
      • Outlook
      • Emal Etiquette
    • Office Etiquette
    • Productivity
    Inside The Web
    Home»Office»Excel»How to Fix “The Key Didn’t Match Any Rows in the Table”

    How to Fix “The Key Didn’t Match Any Rows in the Table”

    Nisha GurungBy Nisha GurungNovember 20, 2023 Excel 4 Mins Read

    If you get an Expression.Error: The key didn’t match any rows in the table in Power BI, it means that you’ve made some changes to your source file and haven’t updated them in the Power Query. 

    In most cases, the error arises when the Sheet’s Name is not the same on your original and destination file. Apart from this, the following causes could also be responsible for the error. 

    • Deleted Sheet or Column in Source File
    • Renamed Column Header/Table
    • Set Privacy Settings in Permission

    Regardless of the cause, in this article, I’ll walk you through these tried and tested fixes to solve the error. 

    Refresh Query

    Firstly, manually Refresh the Query on your Power BI. There are chances that the changes you’ve made on the original data are not updated on the loaded data. For example, added columns/rows, deleted columns, new worksheet, etc.

    On your Power BI desktop, navigate to the Home Tab. Then, from the Queries section, click on Refresh. This should troubleshoot the error.

    Rename Excel Sheet/Columns/Table Names

    Next, you’ll get “The key didn’t match any rows in the table” when the Power Query cannot connect or establish a connection with the data source. This can happen when the Sheet Name, Column headers, or Table names of imported data do not match with the original sheet. 

    For example, maybe you renamed “Sheet3” into “SalesDashboard” in your local workbook. But, there’s still “Sheet3” in the Power BI. 

    So, check and rename the headings to match with the source file. Most users reported this fix resolved their error.

    As an example, I will change the Sheet Name using the Advanced Editor.

    1. On your Power BI Desktop, head to the Home Tab.
    2. From the Queries, click on Transform Data.
      From the Queries, click on Transform Data
    3. Now, on Power Query Editor window, select Sheet3. Click the Home Tab. In the Query group, choose Advanced Editor.
      In the Query group, choose Advanced Editor
    4. On the Advanced Editor Window, enter Sheet name on =Source{Item=""} Here, I will replace the name with “SalesDashboard.” Then, click Done.
      Change Sheet Name from Advanced Editor
    5. Click on Close & Apply.
      Click on Close & Apply

    Delete from Model

    Did you delete an Excel Sheet from your main file? 

    When you delete a sheet that has been loaded in the Power BI, the Power Query cannot access that sheet anymore. Thus, you’ll encounter “The key didn’t match any rows in the table.” 

    Whatever changes you make in the Source workbook, you must update them in the Power BI loaded data too. So, clearing that removed worksheet should solve the error.

    Hover over the Data pane on the right side. Right-click on the Sheet and choose Remove from Model. Pick Yes to confirm.

    Then, click the Refresh menu in the Home tab. The error will no longer appear. 

    Remove Navigation

    Some users who imported the database directly from the SQL server without creating the table also encountered “The key didn’t match any rows in the table.” So, another fix to solve it is to delete the Navigation step on your Power Query. 

    1. From the Home Tab, click on Transform data.
    2. On the Power Query Editor window, hover over the Applied Steps panel. Delete Navigation.
      Delete Navigation
    3. Click Yes. Then, Close the Power Query Editor.

    Clear Permissions

    If you’ve imported the external data source shared by others, it is possible that the user has set Permission settings to protect the workbook.

    Eventually, when you attempt to refresh the  Query, Power Query cannot update the connection or combine data which results in an error.

    In that case, you can clear the Permissions. 

    1. On your Home Tab, click on Transform Data > Data source settings.
      click on Transform Data- Data source settings
    2. Click on Clear Permissions.
      Click on Clear Permissions
    3. Hit Delete. Then, close the window.
      Hit Delete
    Excel Error
    Nisha Gurung

      As a Business Student, Nisha first used Excel to outline data trends for her college projects. Later, she started exploring basic Excel functions when she realized it is a powerful tool for all businesses today. Nisha believes she can relate to many of the issues users face when starting their Excel Journey. She uses this knowledge and experience to curate contents that are fit for all types of Excel users. Apart from writing, she enjoys reading books and traveling.

      Related Posts

      Excel By Nisha Gurung

      How to Compare Two Columns in Excel Using VLOOKUP

      Excel By Nisha Gurung

      How to Share Excel Files with Multiple Users

      Excel By Nisha Gurung

      How to Filter Based on a List in Excel

      Add A Comment
      Table of ContentsToggle Table of ContentToggle
      • Refresh Query
      • Rename Excel Sheet/Columns/Table Names
      • Delete from Model
      • Remove Navigation
      • Clear Permissions
      • Home
      • About Us
      • Privacy Policy
      © 2025 Inside The Web

      Type above and press Enter to search. Press Esc to cancel.