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
MartinC
Helper I
Helper I

How to get a column from table B into Table A?

Hi All,

I've been trying all day to get this done and it's just not working for me 😞  Please help! I know it should be easy but I'm struggling...

So, I have a table called "Milestones" and another table called "UDFS".  They both have a column called "ID".  I want to get the column "UDFValue" from the "UDFS" table into the "Milestones" table.  I've tried creating a new column in the "Milestones" table and using LOOKUPVALUE and RELATED but can't get either to work 😞

Thanks in advance!

1 ACCEPTED SOLUTION

@MartinC Not 100% positive I am fully tracking the issue but perhaps this?

Column =
  VAR __ID = [ID]
  VAR __Result = MAXX(FILTER('UDFS',[ID] = __ID && [UDFID] = 68),[UDFValue])
RETURN
  __Result


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

7 REPLIES 7
MartinC
Helper I
Helper I

@Greg_Deckler I see my error (but don't know how to fix it) - ID in table UDFS has multiple UDFID values - is there a way to filter for the UDFID value of 68 to give the UDFValue for those only? Thanks 🙂

@MartinC Not 100% positive I am fully tracking the issue but perhaps this?

Column =
  VAR __ID = [ID]
  VAR __Result = MAXX(FILTER('UDFS',[ID] = __ID && [UDFID] = 68),[UDFValue])
RETURN
  __Result


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

@Greg_Deckler you are officially my hero! Thank you so much! Side question - where is the best place to learn this sort of thing? I would never have gotten to that solution on my own.

@MartinC That's a great question. I actually just started a new YouTube channel focused on making DAX easy: (2) DAX for Humans - YouTube. I literally just started the channel yesterday. Also, I know that Ben Ferry does some great stuff on his channel and has some "DAX is Easy" stuff in the works, https://www.youtube.com/channel/UCtg3Z9zZSAOkOWCHd-GPbVg.

 

There is a ton of good community content out there but not sure if there is one single thing that takes you from absolute zero and teaches DAX in a logical, incremental manner (hence why I created DAX For Humans). There are a number of self-guided learning paths here: Power BI on Microsoft Learn | Microsoft Learn. Also radacad has a bunch of stuff and sqlbi. @RickdeGroot put together an awesome page that summarizes all of the various stuff out there: Best Resources to Learn Power BI in 2023 (incl DAX, M)

 

Then there are all the books. I have Learn Power BI 2nd Edition which has an introduction to DAX (very light). My book DAX Cookbook has a bunch of recipes for various different DAX calculations. I also like Beginning DAX with Power BI by Philip Seamark and @MattAllington's books, Learn to Write DAX and Supercharge Power BI.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

MartinC_0-1675615131643.png

 

Greg_Deckler
Community Champion
Community Champion

@MartinC You could try a Merge step in Power Query Editor or perhaps try this:

Column =
  VAR __ID = [ID]
  VAR __Result = MAXX(FILTER('UDFS',[ID] = __ID),[UDFValue])
RETURN
  __Result


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

@Greg_Deckler this puts an x in the column (so progress, thanks!) but I need the values from the column?

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.