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'm doing the sales rank, but when I set up the table for presentation the products that had sales with zero appear in the rank table, how do I mount the rank without the products with sales with zero.
Solved! Go to Solution.
Hi @Rfranca,
Try this measure in the Mx_sales table
=RANKX(FILTER(All('PRODUCT'[ProductName]),[Ttotal_Sales]>0),[Ttotal_Sales],,ASC,Skip)
In the Visual level filters, apply a criteria on the Ttoal_Sales of >0
Hope this helps.
Hey @Rfranca!
Try something like this:
MsrRankNo0 = IF( CALCULATE(SUM(Sheet1[Sales])) <> 0, RANKX(ALL(Sheet1),CALCULATE(SUM(Sheet1[Sales])),,1,Skip) - 1 )
You have to subtract 1 to get the rank to start at 1. The calculate expressions are necessary; otherwise, you will get 1s for your ranks. Here is how that turned out on my test data:
hi, @ccakjcrx @gooranga1 @MarcelBeug @vanessa
Unfortunately it did not work out.
I am sending the file for better understanding.
Thank you for your help.
Hi @Rfranca,
Try this measure in the Mx_sales table
=RANKX(FILTER(All('PRODUCT'[ProductName]),[Ttotal_Sales]>0),[Ttotal_Sales],,ASC,Skip)
In the Visual level filters, apply a criteria on the Ttoal_Sales of >0
Hope this helps.
You are welcome.
how to avoid zero values while ranking?
Hi,
That is what my formula suggested on Jan 18, 2018 should do. If it is not working as expected, then share some data, describe the question and show the expected result.
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 |
---|---|
113 | |
99 | |
80 | |
70 | |
59 |
User | Count |
---|---|
149 | |
114 | |
107 | |
89 | |
67 |