Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I would like to create a measure which pulls the top 30 order numbes based on revnue in analysis services tabular model . This data should be pulled from the main fact table and dimension tables.
How to create TOP30 records logic measure in the analysis services without creating any additional tables/Columns?
Solved! Go to Solution.
Hi,
Try this measure
Top 30 orders = calculate([revenue],top(30,all(Orders[Order number]),[revenue]),values(Orders[Order number]))
Hope this helps.
Hi @Anonymous ,
Test the following measure:
revnue Measure
revnue_m = SUM(Ranking[revnue ])
revnue Rank
revnueRank = RANKX(ALL(Ranking),[revnue _m],,DESC,Skip)
TotalSalaryTop30Rank
revnueTop30 = CALCULATE([revnue_m],FILTER(Ranking,[revnueRank ]<=30))
refer:
https://community.powerbi.com/t5/Desktop/Top-10-based-on-a-measure/m-p/460956
Did I answer your question? Mark my post as a solution!
Best Regards
Lucien
Hi,
Try this measure
Top 30 orders = calculate([revenue],top(30,all(Orders[Order number]),[revenue]),values(Orders[Order number]))
Hope this helps.
Hey @Anonymous ,
I think you are looking for the TOPN function: TOPN – DAX Guide
Then you can check if a certain order number is in the TOP 30, flag this order number and filter for the flag.
Hopefully, this gets you started.
Regards,
Tom
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
100 | |
80 | |
64 | |
57 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |