How to create a master-detail report

This topic will guide you through the process of creating a master-detail report with dbForge Studio for SQL Server.

Note that it is recommended that you review the Creating a Simple Data-Aware Report topic first. It will help you learn how to bind report to data with dbForge Studio for SQL Server.

  1. Open the created report definition. For this, in the File menu, click Open.
  2. To create a master-detail report, it’s required to add the Orders table to the report. To add the detail table, drag it from Database Explorer to the Data Source window.
  3. Make the master table active by right-clicking on the table name in the Data Source window and selecting Set Active Item from the shortcut menu:

    Set Active Item

    Note
    In the Data Source tree the Orders_Company and Orders_ShipCompany nodes should be available. If they are not, refresh data in the Data Source tree by clicking the Refresh Data Refresh Data button on the Data Source toolbar.

  4. Right-click on your report in the document area to invoke its shortcut menu. In this menu, point to Insert Detail Report, and select the Orders_Company option to add a new detail report. The Detail Report band will appear:

    Detail Report Band

  5. Right-click the detail report to open the shortcut menu, point to Insert Band, and then click Group Header. This will add the GroupHeaderBand to the detail report:

    GroupHeaderBand

    You can add the Label control to the added GroupHeader band and change text in it to ORDERS DETAILS:.

  6. Add the OrderDate, ShipDate, Freight, and Discount fields from the Orders_Company node of the Data Source tree to the Detail Report band of the report. Near each label with the bound field add labels with the text changed to ‘Order date:’, ‘Ship date:’, ‘Freight:’, ‘Discount:’. You can drag the Line control onto the Detail band to separate orders details from each other.

    Also drag the label with the ‘Phone’ text in it and the one bound to the phone datafield to the Detail band of the detail report to show the phone number as detailed information on customer.

  7. Now switch to the Preview tab at the bottom of the Document area:

    Preview

Download dbForge Studio for SQL Server and try it absolutely free for 30 days!

Want to Find out More?

Overview

Overview

Take a quick tour to learn all about the key benefits delivered by dbForge Studio for SQL Server.
All Features

All features

Get acquainted with the rich features and capabilities of the Studio in less than 5 minutes.
Request a demo

Request a demo

If you consider employing the Studio for your business, request a demo to see it in action.
Ready to start using dbForge Studio for SQL Server?