cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

New Column based on match of 2 fields in same table

I'm trying to do a match based on 2 criteria from within the same table.

 

e.g.

 

My table looks like: 

 

IDemployeeIDAffilliationAffilliationTypetitleFor
112Internal ServicesDivision 
25Health Care ProtectionUnit 
322ChiefTitleUnit
446Consumer ServicesDivision 
522Education & CommunicationsUnit 
619Human ResourcesDivision 

 

I want to add a column that looks for a match of the employeeID and AffilliationType based on employeeID and titleFor of the record.  The result would be:

 

IDemployeeIDAffilliationAffilliationTypetitleFortitleAffilliation
112Internal ServicesDivision  
25Health Care ProtectionUnit  
322ChiefTitleUnitEducation & Communications
446Consumer ServicesDivision  
522Education & CommunicationsUnit  
619Human ResourcesDivision  

 

Thanks in advance for any help or general direction for this.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User III
Super User III

Re: New Column based on match of 2 fields in same table

You could do this with the DAX LookupValue function

 

eg.

 

= LOOKUPVALUE(Table1[Affilliation], Table1[AffilliationType], Table1[titleFor], Table1[employeeID], Table1[employeeID])

View solution in original post

1 REPLY 1
Highlighted
Super User III
Super User III

Re: New Column based on match of 2 fields in same table

You could do this with the DAX LookupValue function

 

eg.

 

= LOOKUPVALUE(Table1[Affilliation], Table1[AffilliationType], Table1[titleFor], Table1[employeeID], Table1[employeeID])

View solution in original post

Helpful resources

Announcements
Community Blog

Community Blog

Visit our Community Blog for articles, guides, and information created by fellow community members.

Using the Community

Using the Community

Need help with the Power BI Community? Our 'Using the Community' support articles are a great place to start.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Power Platform 2020 release wave 2 plan

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors