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!Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote 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.
Vote for your favorite vizzies from the Power BI World Championship submissions!
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 57 | |
| 53 | |
| 42 | |
| 16 | |
| 16 |
| User | Count |
|---|---|
| 112 | |
| 106 | |
| 39 | |
| 36 | |
| 27 |