Good day everyone, I have question about salesforce Report. Suppose I have a product object with field product_name and quantity. Now I want to create a report that will get the total quantity of every product .After that since I have thousands of product, I only want to show top 5 product_name which has the highest quantity.I've tried to used the group by and limit functionality in report, but using it at the same time is not possible. How will i do it please help . Thank you.
Limiting Rows of Summary Report is still not supported in Salesforce.
See this similar Idea on Success Community (Merged with other idea) You'll have to use Custom logic to achieve this.
For Ex : say Report is grouping Opportunities by Account and you're trying to show in Report, Top 5 Accounts with maximum number of opportunities
In that scenario, you've use custom logic like trigger(or preferably batch job, if volume is large) Your custom logic will run each day and find Account with maximum no of opportunities and populate a new 'Custom field' with its ranking. Then you can include this Custom-field in report filter( e.g. Ranking__c in 1,2,3,4,5)
Unfortunately, This is the only way I can think of on this.