Previous Next

Task 8:  Link the orders subreport to the customers master report

You link the orders subreport to the customers master report by binding the CustID parameter to the CUSTOMERNUMBER data set field in the customers report. Each time the customers report reaches a new customer row, the CustID parameter is updated with the new CUSTOMERNUMBER value.

1  
2  
3  
4  
Data Set Parameter Binding displays the CustID parameter, as shown in Figure 13-15. Its value is set to the default, 103, which you specified when you created the data set parameter.

Figure 13-15 Dataset Parameter Binding for the Orders table

Figure 13-15  Data Set Parameter Binding for the Orders table
5  
1  
Select the parameter, then choose Edit. Edit data set parameter binding, shown in Figure 13-16, prompts you to specify a new parameter value.

Figure 13-16 Edit data set parameter binding

Figure 13-16  Edit data set parameter binding

2  
3  
In the expression builder, choose Available Column Bindings, choose List, then double-click CUSTOMERNUMBER. The expression builder displays the expression, row["CUSTOMERNUMBER"], as shown in Figure 13-17.

Figure 13-17 CUSTOMERNUMBER field in the expression builder

Figure 13-17  CUSTOMERNUMBER field in the expression builder
Choose OK to save the expression and close the expression builder.
4  
In Edit data set parameter binding, choose OK to accept the new parameter value. Dataset Parameter Binding displays the new value of row["CUSTOMERNUMBER"] for the CustID parameter, as shown in Figure 13-18.

Figure 13-18 Updated data set parameter binding

Figure 13-18  Updated data set parameter binding
6  
7  

Figure 13-19 Preview of the report shows correct orders data

Figure 13-19  Preview of the report shows correct orders data
Now different order records appear for different customers. Not all customers have order records. To display only customers that have orders, you change the query for the customers report. This task is described later in Task 11: “Display only customers that have orders or payments.”

(c) Copyright Actuate Corporation 2012