Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hi folks!
I need to ranking my sellers using 5 KPIS x target, its possible using IF and RANK?
Ex:
Target KPI A = 95%
Target KPI B = 80%
Seller 1 -
KPI A = 90%
KPI B = 80%
Seller 2 -
KPI A = 100%
KPI B = 80%
-
MONTH RANK
1º -Seller 2
2º Seller 1
Rgdrs,
Solved! Go to Solution.
Hi @Campolas ,
I created some data:
Here are the steps you can follow:
1. Select two columns – Unpivot Columns.
2. Create calculated column.
Index =
IF(
'Table'[Value]>='Table'[Target],
RANKX(
FILTER(ALL('Table'),
'Table'[KPI]=EARLIER('Table'[KPI])),[Value],,DESC),0)
3. Create measure.
Rank =
SUMX(
FILTER(ALL('Table'),
'Table'[Attribute]=MAX('Table'[Attribute])),[Index])
4. Result:
If you need pbix, please click here.
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Hi @Campolas ,
I created some data:
Here are the steps you can follow:
1. Select two columns – Unpivot Columns.
2. Create calculated column.
Index =
IF(
'Table'[Value]>='Table'[Target],
RANKX(
FILTER(ALL('Table'),
'Table'[KPI]=EARLIER('Table'[KPI])),[Value],,DESC),0)
3. Create measure.
Rank =
SUMX(
FILTER(ALL('Table'),
'Table'[Attribute]=MAX('Table'[Attribute])),[Index])
4. Result:
If you need pbix, please click here.
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
Thnx a lot!!! Sorry bout delay!
@Campolas , see if this can help
You can have like
Switch(selectedvalue([KPI])
"KPI1", Rankx(allselected(Table[seller]), [KP1],
"KPI2", Rankx(allselected(Table[seller]), [KP2],
"KPI3", Rankx(allselected(Table[seller]), [KP3],
"KPI4", Rankx(allselected(Table[seller]), [KP4],
"KPI5", Rankx(allselected(Table[seller]), [KP5] )
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!
| User | Count |
|---|---|
| 20 | |
| 11 | |
| 9 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 31 | |
| 29 | |
| 21 | |
| 12 | |
| 12 |