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
LNNRTS
New Member

Need help: Adding a category to duplicates based on a previous categorization.

Hey there,
disclaimer: I'm a total newbie to DAX, quite experienced with excel but I thought it's time to automate my data via power pivot (Excel not PowerBI) 😅

I have two tables. "projects" is listing every manager and the projects they're working on. Another table "managers" listing every manager just once incl. further info such as if he's a "top" manager. In the end, I would like to filter my pivot table to show me every project where a "top" manager is NOT involved. As I understand it right, I have to add the information to the main "projects" Table. First I did a simple lookup in the "Projects" table based on the "Managers" table. But now I have to add the info to every row with a project having a "top" manager involved, as shown below in the desired "inclTopMgmt" collum. The original data is much more complex so that there a 100k of "projects".

Glad for every kind of help/hints etc. Thanks in advance!

Projects table with the desired "inclTopMgmt" collum:
Manager         Projects      Lookup(Managers)       inclTopMgmt
A                       PA                                                    true
A                       PB
B                       PA               top                                true
B                       PC               top                                true
C                       PA                                                    true

Managers Table:
Manager       Status
A                   
B                    top
C

2 REPLIES 2
LNNRTS
New Member

Hey @Jihwan_Kim,
thank you already! Unfortunately it didn't really work. Maybe due to the fact that I'm using power pivot (in Excel) and not PowerBI? (therefore I'm also not able to check your file 😕 )
I'm still trying to fix it / understanding your approach - maybe it's due to my other calculated collums .... ? 

PowerPivot.PNG

Jihwan_Kim
Super User
Super User

Hi, @LNNRTS 

Please check the below picture and the sample pbix file's link down below.

Picture1.png

 

InclTopMgmt Measure =
IF (
ISFILTERED ( Projects[Projects] ),
IF ( MAXX ( Projects, RELATED ( Managers[Status] ) ) = "top", "true", "" )
)
 
 
 

Hi, My name is Jihwan Kim.


If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.


Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Go to My LinkedIn Page


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.

Top Solution Authors