Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Diptarup
Helper II
Helper II

Getting Sum except TOP 10 rank

I have table, wherein I need to calculate the value of all products which are ranked in Top 10 .

Table below :- 

So the value I am looking for is 38.46.

I have used a meaure to calculate the rank, which is given below:-

Top10 =
Var VendorRank = RANKX(ALL(Table1[Products]),[Amount (Recal)],,DESC)
Return
IF(VendorRank>10,[Amount (Recal)],BLANK())
What is happening, is that I am getting the Overall value of 41.61 and not 38.46. Any help is highly appreciated. 

Table 1

ProductsValue
A15.00
B10.96
C2.82
D2.45
E1.55
F1.50
G1.40
H1.36
I0.72
J0.70
K0.60
L0.44
M0.43
N0.39
O0.36
P0.36
Q0.29
R0.29

 

1 ACCEPTED SOLUTION
Ritaf1983
Super User
Super User

Hi @Diptarup 
You can use :

SumTOPN =
CALCULATE ( [sum_], TOPN ( 10, 'Table', 'Table'[Value] ))
Ritaf1983_0-1714035546151.png

pbix is attached

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

View solution in original post

1 REPLY 1
Ritaf1983
Super User
Super User

Hi @Diptarup 
You can use :

SumTOPN =
CALCULATE ( [sum_], TOPN ( 10, 'Table', 'Table'[Value] ))
Ritaf1983_0-1714035546151.png

pbix is attached

If this post helps, then please consider Accepting it as the solution to help the other members find it more quickly

Regards,
Rita Fainshtein | Microsoft MVP
https://www.linkedin.com/in/rita-fainshtein/
Blog : https://www.madeiradata.com/profile/ritaf/profile

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.