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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Join two tables repeating rows

So, I think it's a simple problme, but I can't resolve it on time.

 

I have a table A with two columns: Employee and Code.

And table two with two columns too: Code and Course.

 

Table 1:

FelipeJaworoski_0-1683753708022.png

 

Table 2:

FelipeJaworoski_1-1683753742616.png

 

I want to make a third column joining the info from table 2 to table 1, but not on Power Query it has to be with DAX.

The final result is something like this:

FelipeJaworoski_2-1683753815121.png

Can anyone help, please?

 

1 ACCEPTED SOLUTION
wdx223_Daniel
Super User
Super User

NewTable=GENERATE(Table1,CALCUATETABLE(VALUES(Table2[Course]),TREATAS(VALUES(Table1[Code]),Table2[Code])))

View solution in original post

2 REPLIES 2
wdx223_Daniel
Super User
Super User

NewTable=GENERATE(Table1,CALCUATETABLE(VALUES(Table2[Course]),TREATAS(VALUES(Table1[Code]),Table2[Code])))

Anonymous
Not applicable

It works. Thank you!!

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.