How to Merge Tables in Power BI

In this Power BI tutorial, we will learn how to merge tables in Power Bi and also will see how to merge tables with different columns in Power Bi. In addition, we will also cover how to merge tables using Power Bi Dax.

How to Merge Tables in Power BI

Here we will see how to merge two tables in Power Bi. In this example, we are going to use the Team Appearances Table consists of two tables called Team A and Team B as below:

Team A:

How to Merge Tables in Power BI
How to Merge Tables in Power BI

Team B:

How to Merge Tables in a Power BI
How to Merge Tables in a Power BI
  • Load the data using the get data option into Power Bi desktop. Then click on transform data from the ribbon on the power bi desktop, it will redirect to the power query editor.
Merge Tables in a Power BI
Merge Tables in a Power BI
  • In the Power Query editor, choose the Merge queries option. In the merge query, pop-up window choose the Table names and columns and click on the Ok button.
Merge Tables in a Power BI example
Merge Tables in a Power BI example
  • Once you click on the OK button, you can see that the two queries have been merged and combined into a new table.
  • Then Expand the column and select the column you want to display in the merged table, here I will expand the Team B members count.
How to Merge Tables in a Power BI example
How to Merge Tables in a Power BI example
  • In the below screenshot, you can see that the value has been expanded and displayed as below: Now click on the close and apply the option to save the changes.
Merge Tables in the Power BI
Merge Tables in the Power BI

This is how to merge two different tables in the Power Bi report.

Merge tables in power bi with different columns

Let us see how we can add the merge table in Power Bi with different columns in Power Bi.

  • Load the data using get data into the Power Bi desktop. Then click on transform data from the ribbon on the power bi desktop, it will redirect to the power query editor.
  • In the Power Query editor, choose the merge queries option. We can select different columns with the same data type value.
  • In the merge query, pop-up window choose the Table names and columns and click on the ok button.
Merge tables in power bi with different columns
Merge tables in power bi with different columns
  • Once you click on OK, merge the two queries and create a new table.
  • Then Expand the column and select the column you want to display in the merged table.
  • In the below screenshot, we can see that it displays the team names for the selected value, and for the unmatched values, it displays the null value.
  • Now click on the close and apply the option to save the changes.
Merge tables in power bi with different columns example
Merge tables in power bi with different columns example

This is how to add the merge table in Power Bi with different columns in Power Bi.

How to merge two tables in power bi using Dax

Here we will see how to merge or combine two tables using the Power Bi Dax.

  • Load the data using get data into the Power Bi desktop. under the modeling, tab clicks on the new measure and apply the below-mentioned formula:
Merged Table = UNION('Team A','Team B')

Where,

  1. Merged Table = New Table Name
  2. UNION = Function Name
  3. Team A & Team B = Existing Table Names

The screenshot below displays the newly merged data table values in the Power Bi data section.

How to merge two tables in power bi using Dax
How to merge two tables in power bi using Dax

This is how to merge or combine two tables using DAX in Power Bi.

This Power Bi tutorial clearly demonstrated how to merge tables in Power Bi and also how to merge tables with different columns in Power Bi. In addition, we also covered how to merge tables using Power Bi Dax.

You may like the following power bi tutorials:

>