Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I am trying to return the group for the max value of Consumer Uplift Pre vs Dur.
I had it working with a topn formula but that didnt return a group if the value was negative.
Any ideas?
CALCULATE
(LASTNONBLANK ( 'Attributes'[SecondaryGroup],1)
,MAXX(KEEPFILTERS(VALUES('Attributes'[PrimaryGroup])),CALCULATE([Consumer Uplift Pre vs Dur])),TRUE())
Solved! Go to Solution.
Yeah, those can get annoying. I think you need something like [Primary Group] = MAXX(...
But, tough to really say with your formula. I reformatted it to this to make it easier to understand. I have no idea what the TRUE() is doing for you.
CALCULATE(
LASTNONBLANK ( 'Attributes'[SecondaryGroup],1),
MAXX(
KEEPFILTERS(
VALUES('Attributes'[PrimaryGroup])
),
CALCULATE([Consumer Uplift Pre vs Dur])
),
TRUE())
Yeah, those can get annoying. I think you need something like [Primary Group] = MAXX(...
But, tough to really say with your formula. I reformatted it to this to make it easier to understand. I have no idea what the TRUE() is doing for you.
CALCULATE(
LASTNONBLANK ( 'Attributes'[SecondaryGroup],1),
MAXX(
KEEPFILTERS(
VALUES('Attributes'[PrimaryGroup])
),
CALCULATE([Consumer Uplift Pre vs Dur])
),
TRUE())
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!