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
Hi every one,
I try Topn Sales with "Sub-Cat" wise contribution %. Here i need to show my percentage values with TopN sales by elimating unwanted data.
Contribution % formula is:
GT% Values = [Total Sales] / (CALCULATE(SUM(Orders[Sales]), ALLSELECTED(Orders[Sub-Category] )))
Output should come like below...
| Sub-Category | TopN SubCat | GT% Values |
| Phones | 1857159.027 | 13.54% |
| Chairs | 1642421.76 | 11.97% |
| Copiers | 1594855.209 | 11.63% |
| Bookcases | 1516835.595 | 11.06% |
| Storage | 1233162.199 | 8.99% |
| Appliances | 1065196.174 | 7.77% |
| Machines | 862912.0331 | 6.29% |
| Tables | 845985.4444 | 6.17% |
How can i achive this....
Thanks in advance...
Solved! Go to Solution.
Hi @venug20,
Update your formula as below.
GT% Values = IF(ISBLANK([TopN subcate]),BLANK(), [total sales]/CALCULATE(SUM(Orders[Sales]),ALLSELECTED(Orders[Sub-Category])))
Alsp please find the pbix as attached.
Regards,
Frank
Hi @venug20,
Update your formula as below.
GT% Values = IF(ISBLANK([TopN subcate]),BLANK(), [total sales]/CALCULATE(SUM(Orders[Sales]),ALLSELECTED(Orders[Sub-Category])))
Alsp please find the pbix as attached.
Regards,
Frank
Sample source data please. Please see this post regarding How to Get Your Question Answered Quickly: https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 39 | |
| 38 | |
| 38 | |
| 28 | |
| 26 |
| User | Count |
|---|---|
| 124 | |
| 87 | |
| 70 | |
| 66 | |
| 65 |