The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hello,
I am trying to Rank Category Id from category table as per Quantity sold in quantity sold table.
please refer the below table-
I am using this formula-
Solved! Go to Solution.
Hi,
Yeah I believe you should have a relationship between Category table as well as the Quanity sold table. Also, the formula looks a bit incorrect.
Once the relationship is setup properly then try using this on. I have separated the two measures so that it becomes more clear.
Total Quanity = SUM(QuanitySold[Qauntity Sold])
Rankbycategory - RANKX(ALLselected('Product'[CategoryID]), [Total Quantity], , DESC)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks
Radhika
Hi @Anonymous ,
Pls check whether there is some conflict relationships between "category" and "quantity sold"?
As tested here,if you only have 3 tables with the relationships shown in original post,it works fine:
If you still couldnt find the problem,would you pls share your .pbix file for test?
Remember to remove the confidential information.
For my sample .pbix file,pls see attached.
Best Regards,
Kelly
Did I answer your question? Mark my reply as a solution!
Hi,
Yeah I believe you should have a relationship between Category table as well as the Quanity sold table. Also, the formula looks a bit incorrect.
Once the relationship is setup properly then try using this on. I have separated the two measures so that it becomes more clear.
Total Quanity = SUM(QuanitySold[Qauntity Sold])
Rankbycategory - RANKX(ALLselected('Product'[CategoryID]), [Total Quantity], , DESC)
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks
Radhika
User | Count |
---|---|
70 | |
64 | |
62 | |
49 | |
28 |
User | Count |
---|---|
117 | |
75 | |
61 | |
54 | |
42 |