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
BrianSK
Regular Visitor

Two columns with different values in one table pointing to a single column of another table.

Hi,

 

Two fields of project table, ProjectIntitator and ProjectManager has values of WorkerId from WorkerTable.

 

I need to display names of ProjectInitiator and ProjectManager, but the name field from Worker table will always display only one value...

 

I created a new table as WorkerTableMgr(WorkerTable) and pointed ProjectManager of project table to WorkerId in new table.

 

But I am trying to figure out if we can have any other way to achieve this instead of duplicating the whole table..

1 ACCEPTED SOLUTION
v-yulgu-msft
Employee
Employee

Hi @BrianSK,

 

Based on my assumption, I created two sample tables like below:

ProjectTable                                        WorkerTable

1.PNG2.PNG

 

You want to display corresponding name from WorkerTable in ProjectTable, right? If so, please create calculated columns in ProjectTable as below:

Name of Intitator = LOOKUPVALUE('Worker Table'[Name],'Worker Table'[WorkerId],'Project  Table'[ProjectIntitator])

Name of Manager = LOOKUPVALUE('Worker Table'[Name],'Worker Table'[WorkerId],'Project  Table'[ProjectManager]) 

3.PNG

 

Best regards,
Yuliana Gu

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

View solution in original post

4 REPLIES 4
v-yulgu-msft
Employee
Employee

Hi @BrianSK,

 

Based on my assumption, I created two sample tables like below:

ProjectTable                                        WorkerTable

1.PNG2.PNG

 

You want to display corresponding name from WorkerTable in ProjectTable, right? If so, please create calculated columns in ProjectTable as below:

Name of Intitator = LOOKUPVALUE('Worker Table'[Name],'Worker Table'[WorkerId],'Project  Table'[ProjectIntitator])

Name of Manager = LOOKUPVALUE('Worker Table'[Name],'Worker Table'[WorkerId],'Project  Table'[ProjectManager]) 

3.PNG

 

Best regards,
Yuliana Gu

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

Thanks a lot Yuliana !

austinsense
Impactful Individual
Impactful Individual

Here's one approach to get you thinking ... https://powerpivotpro0-my.sharepoint.com/personal/austin_powerpivotpro_com/_layouts/15/guestaccess.a...

 

The relationship between projects and workers is complex, it's many to many.

Austin is VP Operations at PowerPivotPro and a professional self-service enthusiast 🙂
Ashish_Mathur
Super User
Super User

Hi,

 

Share a sample dataset and show the expected result.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

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.