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! It's time to submit your entry. Live now!
Hello, I am making a dashboard with open data on Bullying in Peru and I want to make a top 10 of the subtypes of violence, it should be noted that they are string data, and use this dax:
Solved! Go to Solution.
The TOPN is changing the fitler context to override the line, try it with a KEEPFILTERS.
Top10 =
CALCULATE (
[Subtypes],
KEEPFILTERS (
TOPN ( 10, ALL ( 'DM Facts'[SUBTIPO_VIOLENCIA] ), [Subtypes], DESC )
)
)
Hi,
Share the download link of the PBI file.
I didn't know I had to share the download link.
The TOPN is changing the fitler context to override the line, try it with a KEEPFILTERS.
Top10 =
CALCULATE (
[Subtypes],
KEEPFILTERS (
TOPN ( 10, ALL ( 'DM Facts'[SUBTIPO_VIOLENCIA] ), [Subtypes], DESC )
)
)
Indeed this is the solution, thank you very much.
The Power BI Data Visualization World Championships is back! It's time to submit your entry.
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 60 | |
| 47 | |
| 39 | |
| 24 | |
| 23 |
| User | Count |
|---|---|
| 144 | |
| 106 | |
| 63 | |
| 38 | |
| 31 |