MSSQL Server Reporting Services: Black Belt Components: Ad Hoc Sorting with Parameters - Page 5April 19, 2005 Enhance the Territory Sales Drilldown Report Structure to Meet Business Requirements Let's open the new clone of the Territory Sales Drilldown report, and begin our alterations, focusing upon the conditional sorting considerations that form the nucleus of our session. We will first create the parameter structures to support the required ad hoc sorting capabilities, and then we will make modifications to the affected data region of the report itself to complete our enhancements. 1. Double-click AdHocSort_Territory Sales Drilldown.rdl, within the Reports folder in Solution Explorer, to open it in Report Designer. The report opens, displaying the report on the Layout tab. 2. Select Report --> Report Parameters from the main menu, as depicted in Illustration 18.
The Report Parameters dialog appears. 3. Click the Add button in the lower left corner of the dialog. A new parameter with default name appears. 4. For the dialog boxes shown in Table 1, type the corresponding items (replacing defaults where required):
Table 1: Sort Selection Parameter Settings The completed Report Parameters dialog for the sort selection parameter appears as shown in Illustration 19.
This provides us with the parameter we need for the sort selection. Next, we need to create a parameter whereby we can specify the sort direction. We will do this with the following steps: 5. Click the Add button in the lower left corner, once again. A new parameter with default name appears. 6. For the dialog boxes shown in Table 2, type the corresponding items (replacing defaults where required):
Table 2: Sort Direction Parameter Settings |