Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
mmh
Helper I
Helper I

same repoort with different join(merge) in same dataset

Hi,

I have one report where dataset need to to merge two ways, ie. left join with  one column  and another join with same datset, same tables but within 3 columns. is it posible to make it within one report or need to generate two report.

 

Thanks

MMH

1 ACCEPTED SOLUTION
Adamboer
Responsive Resident
Responsive Resident

Yes, it is possible to merge two ways within one report. You can achieve this by using Power BI's merging and joining capabilities.

Here are the steps you can follow to merge the dataset in two ways:

  1. Import the dataset into Power BI.

  2. Select the "Modeling" tab and then click on "New Table" to create a new table.

  3. In the formula bar, enter the formula for left join with one column. For example, if you want to left join Table1 with Table2 on the "ID" column, the formula would be:

    LeftJoinTable = LEFT JOIN(Table1, Table2, "ID")

    Create another new table, and in the formula bar, enter the formula for the second join. For example, if you want to inner join Table2 with Table1 on the columns "ID", "Date", and "Product", the formula would be:

    InnerJoinTable = INNER JOIN(Table2, Table1, {"ID", "Date", "Product"})

    By following these steps, you should be able to merge your dataset in two ways within one report.




    You can now use the "LeftJoinTable" and "InnerJoinTable" in your report as needed.

View solution in original post

4 REPLIES 4
Adamboer
Responsive Resident
Responsive Resident

Yes, it is possible to merge two ways within one report. You can achieve this by using Power BI's merging and joining capabilities.

Here are the steps you can follow to merge the dataset in two ways:

  1. Import the dataset into Power BI.

  2. Select the "Modeling" tab and then click on "New Table" to create a new table.

  3. In the formula bar, enter the formula for left join with one column. For example, if you want to left join Table1 with Table2 on the "ID" column, the formula would be:

    LeftJoinTable = LEFT JOIN(Table1, Table2, "ID")

    Create another new table, and in the formula bar, enter the formula for the second join. For example, if you want to inner join Table2 with Table1 on the columns "ID", "Date", and "Product", the formula would be:

    InnerJoinTable = INNER JOIN(Table2, Table1, {"ID", "Date", "Product"})

    By following these steps, you should be able to merge your dataset in two ways within one report.




    You can now use the "LeftJoinTable" and "InnerJoinTable" in your report as needed.
mmh
Helper I
Helper I

can you share idea please

In addition to what Adamboer suggested, you can also do this in Power Query if you'd like to do the joins before loading to the model.

  • Start with your two queries (Table1 and Table2) in the Power Query Editor
  • Select Table1, and then from the Home ribbon choose Merge -> Merge Queries as New
  • Enter the settings for your first join and click OK
  • Select Table1 and once again click Merge Queries as New
  • Enter the settings for your second join and click OK
Ehren
Employee
Employee

Yes, you should be able to do this in one report.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors