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
Hey I am wondering if rankx can be used in the following case:
Basically I want to see the top 3 projects with the most logged hours for a given portfolio:
the final result should look like this:
Portfolio | Project | Hours Logged
---------------------------------------
Portfolio 1 | project 1 | 10000
---------------------------------------
Portfolio 1 | project 8 | 5000
---------------------------------------
Portfolio 1 | project 9 | 2000
---------------------------------------
Portfolio 2 | project 0 | 15000
---------------------------------------
Portfolio 2 | project 3 | 7000
---------------------------------------
Portfolio 2 | project 11 | 2000
---------------------------------------
Solved! Go to Solution.
Use this dax:
Ranking =
RANKX (
ALLEXCEPT ( Table1, Table1[Portfolio] ),
CALCULATE ( SUM ( Table1[HoursLogged] ) ),
,
DESC,
DENSE
)In visual level filter select
Use this dax:
Ranking =
RANKX (
ALLEXCEPT ( Table1, Table1[Portfolio] ),
CALCULATE ( SUM ( Table1[HoursLogged] ) ),
,
DESC,
DENSE
)In visual level filter select
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 38 | |
| 38 | |
| 37 | |
| 28 | |
| 28 |
| User | Count |
|---|---|
| 124 | |
| 89 | |
| 73 | |
| 66 | |
| 65 |