Using Parameters to Connect to Other Reports
You can use parameters to relate main reports to drillthrough reports, to subreports, and to linked reports. When you design a set of reports, you typically design each report to answer certain questions. Each report can provide a different view or a different level of detail for related information. To provide a set of interrelated reports, create parameters for the related data on target reports. How to pass the appropriate parameter to the target report depends on the type of target report.
Drillthrough actions are set on the property pages for any text box for a report item. If the target of the drillthrough action is a report local to the report project, you can use the Parameters button on the Navigation tab of the property page to set the parameter values to pass to the target report. The parameter names will appear in the drop-down list for the local report. For more information, see Textbox Properties (Navigation Tab, Report Designer).
If the target report is on the report server but not in the local directory, you will need to discover the parameter names of the target report by examining the report properties with Report Manager or SQL Server Management Studio. You can then manually enter the parameter names and the default values. Parameter names are case-sensitive.
You can use URL Access for any URL-addressable report and include report parameter values as part of the URL syntax. For more information, see URL Access.
Examples of drillthrough reports can be found in the AdventureWorks sample Product Line Sales report.
A subreport must be a report in the report server project. To set parameters for a subreport, use the Parameters tab of the property pages for the subreport report item.
|If you use a subreport in a data region, the subreport and its parameters will be processed for every row in the data region. For this reason, consider whether a drillthrough is more appropriate.|
For more information, see How to: Add a Subreport and Parameters (Report Designer). For an example, see Tutorial: Advanced Features Using Parameters.
After a report is published, you can create a linked report from the published report. A linked report can be thought of as a pointer to the main report, but with a separate set of parameters. After you create the linked report, open it in Report Manager or SQL Server Management Studio and modify the parameters. YFor more information, see Setting Parameter Properties for a Published Report. Because parameters are managed independently on the server, republishing a main report with new parameter settings does not overwrite the existing parameters settings for either the main report or the linked report. For more information, see New Linked Report Page (Report Manager) or How to: Create a Linked Report.
For reports rendered in HTML, you can open a report at a specific location by using bookmark labels in the report and passing a parameter value in the URL address when the report is opened via a URL. For more information, see Passing a Report Parameter Within a URL.
TasksHow to: Associate a Query Parameter with a Report Parameter (Report Designer)
How to: Add, Edit, or Delete a Report Parameter (Report Designer)
ConceptsSetting Parameter Properties for a Published Report
Adding, Modifying, and Deleting Linked Reports
Adding Links to a Report
Adding a Subreport
Working with Report Items
Other ResourcesTutorial: Adding Parameters to a Basic Tabular Report
Tutorial: Advanced Features Using Parameters
Report Parameters (Report Designer)