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

Return list based on another table

Hey folks,

 

My Table1 has the names of employees and a project activity on each line. I have a new table with an updated column of employees , and I want to list all their projects in table 1, except employees that weren't on the original list. Capture.PNG

So far, I have two columns with the distinct names and projects from the previous table contained in each list. The next column should check if the current row employee is contained in the list, if so then create a table containing the employee's name and projects. My code right now keeps returning errors. Hope someone can help, thanks!

 

if 
      List.Contains(each [All Names], each [Employee])
then 
      Table.Select(Table1,Table1[Name] = Table2[Employee])
1 REPLY 1
v-yuezhe-msft
Employee
Employee

@pierre415,

Firstly, there is no Table.Select() function in Power Query, Table.SelectColumns() and Table.SelectRows() functions are available, For more Table functions, please review this article.

Secondly, I am not quite sure about your desired result, please share sample data of the Table2 and post expected result in table based on the sample data.


Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.