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!View all the Fabric Data Days sessions on demand. View schedule
Can you help me with measure which return maximum monthly sales value
Table Sales contains sales values for every day in 2022
| Date | Sales | |
| 1/1/2022 |
| 2000 |
| 1/2/2022 | 3000 | |
| 1/3/2022 | 1000 | |
| .... | ||
30/12/2022 | 5000 | |
31/12/2022 | 1000 |
and result will be month which have max (highest) sales in the month e.g.
| Month | Sales | |
| Jun2022 | 150000 |
Thank you
Solved! Go to Solution.
@Tricx , you can use TOPN
Maxx(TOPN(1, allselecetd(table[Month]), calculate(sum(Table[Sales])) , desc) , [Month])
Dynamic TOPN using TOPN/Window and Numeric parameter: https://youtu.be/vm2mdEioQPQ
@Tricx , you can use TOPN
Maxx(TOPN(1, allselecetd(table[Month]), calculate(sum(Table[Sales])) , desc) , [Month])
Dynamic TOPN using TOPN/Window and Numeric parameter: https://youtu.be/vm2mdEioQPQ
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 |
|---|---|
| 18 | |
| 11 | |
| 9 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 31 | |
| 25 | |
| 21 | |
| 14 | |
| 12 |