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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
mattio
Frequent Visitor

Combine table

Hello, a quick question as I have not been able to find out an answer anywhere.

Is there a PQ function that can join two tables without using the merge function I.e. there are no keys but the tables are ordered and are have the same rows

Example Table 1
Id|Fruit
1|apple
2|strawberry
3|banana

Example Table 2
Colour
Green
Red
Yellow

Example result table
Id|Fruit|colour
1|apple|green
2|strawberry|red
3|banana|yellow

My real data is much larger and changes often. In excel all I would do is take one column copy it and paste it next to the other.

Thanks
2 REPLIES 2
Anonymous
Not applicable

Hi,

You can create an index column in query editor for Table 2 and then join it with Table 1.

Then you can use RELATED function in DAX to get the desired column.

Color = RELATED( Table2[ Color ] ) 

Thanks.

thanks, however i am looking to join using query not DAX, and i understand how to join using the merge and a unique key.

 

I am trying to combine the tables as if there were no relationship between the two tables. if you imagine copying one column and pasting it next to the other in excel terms

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

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.