Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.
Here is the text to get the top spender, how to get the second highest spender?
Hi @StephenF ,
You could create a measure like
top 2 =
CONCATENATEX (
FILTER (
ALLSELECTED ( 'Table'[ID]),
RANKX (
ALLSELECTED ( 'Table'[ID]),
CALCULATE ( SUM('Table'[Sales]) ),
,
DESC
) <= 2
),
'Table'[ID],
", ",
RANKX (
ALLSELECTED ( 'Table'[ID] ),
CALCULATE ( SUM('Table'[Sales]) ),
,
DESC
)
)
Then you'll get the dynamic top 2.
Best Regards,
Stephen Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Now, how to get the second highest sale only..
@StephenF , I tried a few combinations like 2nd highest, rank 2, Seem like you need to train it to use rank for such a case
Check out the November 2023 Power BI update to learn about new features.