Creating Reports (.RDL Files) Manually - SQL Server Reporting Services

You can use Business Intelligence Development Studio or Report Designer to easily design your reports, but sometimes, especially when you migrate existing reports, you may find useful to develop or generate report definition files (RDL) directly.

RDL File Structure

RDL file is a XML file containing a report definition:

  • Report data - Connection string, query, fields etc. to obtain the data to display in the report
  • Calculations - Calculations and transformations on the report data (grouping, sorting, filtering, aggregations, scalar formulas etc.)
  • Report Layout - Specifies how to present the data and calculations in the resulting report

<Report> is the root element of an RDL document.

Minimal Valid RDL File (Blank Report)

Minimal Valid RDL file without the data and layout (blank report) that you can open in Report Designer must contain Report, ReportSections, ReportSection, Body, Page, Width and Height elements:

   <?xml version="1.0" encoding="utf-8"?>
   <Report xmlns:rd="" 

Note. ReportSections and ReportSection elements are required for RDL 2010 specification (SQL Server 2008 R2)

Defining Report Data

To define the data for a report, you have to specify one or more data sources (connection information), one or more data sets (query and fields):

     <DataSource Name="DataSource1">
          <ConnectString>Data Source=serverHost;Initial Catalog=databaseName</ConnectString>
    <DataSet Name="DataSet1">
          <CommandText>select * from cities</CommandText>
          <Field Name="city">
          <Field Name="country">
          <Field Name="continent">

Migration Resources


, January 17, 2013 6:47 am

the information provided above is good for basic understanding about the reporting…manually how to configure the report using this .rdl file which is in xml format.there are some special attribute or elements in the xml file need to deep understand……

You could leave a comment if you were logged in.