There is another filter option you can use when want to report only the highest, first, or top ‘N’ values from each group. This is called Top N and you find it on the Filter Results tab of the Workbench window.
Lesson Goals: You are going to show the three most profitable cars for each dealer.
To specify a Top N Value:
- From the Request Manager, highlight the Request LESSON7, Profit Analysis.
- Right-Click then click on Save As.
- Change the Request Name to xxxLESS7 (substituting your initials for xxx).
- Change the Request Title to “Profit Analysis Top 3 Cars for Each Dealer.”
- Click OK.
- From the Request Manager, highlight the xxxLESS7 (substituting your initials for xxx).
- Click the Preview icon on the toolbar. You will see that Bay Cities Auto Auction has a large number of cars listed
- Click the X on the upper right corner of the Request Preview window to close the window.
- From the Request Manager, right-click on xxxLESS7 choose Filter.
- Click Top N.
- Check the “Include only the first” check-box.
- Change the number of values to 3.
- Select “Gross Profit for each Sold To Dealer Name” in the drop-down box.
- Click OK.
- Click the Save icon in the Design Preview toolbar.
- Click the Close icon on the Design Preview toolbar.
- Highlight the xxxLESS7 Request and click the Preview icon on the toolbar to preview it.The output will now show just the 3 most profitable cars for each dealer.
If two cars have the same profit, there will be 4 cars shown in the output. - Click the X on the upper right corner of the Request Preview window to close the window.