Great. This is a good sample file. Now some questions.
- The sum of the 5 largest "values" provided they are "carrots"
5 largest (carrot) values as per <what>? Can you mock up the expected result?
then, the sum of the top 15, then top 40 -- As above, top 15 of what? These will need to be different pivot tables to sum different settings. Mock up the correct result for your data sample, so we know what to aim for.
- The sum of the 5 (then 15, 40) largest "values" provided they are "carrots" for a period of time inferior to X numbers of weeks ("date"). -- Again, mock up the desired result. Which of the data rows qualify? Why?
While I said that this can be done with Pivot Tables, I still need the exact business logic to apply the correct filter.
"the 5 (then 15, 40) largest " Such a sort is not possible within a single pivot table. You need separate pivots to do that.
As soon as you can mock up some results based on your data and your logic, I'll try to build it with a pivot table.
Bookmarks