Share this Page URL

Chapter 10. Presenting Data with Reports > Filtering Records in a Report - Pg. 353

Presenting Data with Reports 2. 3. 353 If the Properties dialog box isn't displayed, click the Properties button on the toolbar. On the Data tab, click in the Record Source property, and then click the Build button. The Query Builder opens, as shown here: 4. 5. On the toolbar, click the Show Table button. In the Show Table dialog box, click the Queries tab, select qryPercentOfBudget, click Add, and then click Close. The fields in this query calculate the total expenses for a campaign and the percentage of the budget spent. By adding this query to the report's record source, we can include this summary data in the report. As an alternative, you could create calculated controls on the report to display this information. To relate records in the query with records in the MarketingCampaigns table, click Country in the field list for the MarketingCampaigns table, and then drag it to the Country field in the field list for the PercentOfBudget query, as shown here: 6. 7. From the field list for the MarketingCampaigns table, add CampaignBudget to the first blank column in the query design grid. From the field list for qryPercentOfBudget, add the fields SumOfAmountSpent and PercentOfBudget. Close the Query Builder, and click Yes in the message box asking whether you want to update the query and the Record Source property.