ptg
31
Reporting Services Extensions
2
Reporting Services Extensions
An extension is a .NET assembly that is invoked by the report processor to perform certain
processing functions. There are several types of extensions: data processing, delivery,
rendering, security (authentication and authorization), semantic query, model generation,
and event processing.
For an extension to be used by a Report Server, it has to be installed (assuming default
SSRS configuration) to the
C:\Program Files\Microsoft SQL
Server\MSRS10.MSSQLSERVER\Reporting Services\ReportServer\bin
directory and
configured in
C:\Program Files\Microsoft SQL Server\MSRS10.MSSQLSERVER\Reporting
Services\ReportServer\ReportingServicesService.exe.config
.
The last part of an extension filename usually implies the extension’s functionality. For
example, the HTML rendering extension’s filename is
Microsoft.ReportingServices.HtmlRendering.dll
.
Custom extensions enable developers to add complementing functionality that is not
available in SSRS “out of the box.” For example, a company can implement an extension
that delivers reports to a phone or a fax. You can learn more about extensions in Chapter
29, “Extending Reporting Services.”
NOTE
This release of SSRS does not allow custom semantic query, model-generation, or
event-processing extensions.
Data-Processing Extensions
Data-processing extensions retrieve data from the report data source. Some of the tasks
version.
Oracle Connects to and retrieves data from an Oracle database; requires
Oracle client 8i Release 3 (8.1.7) to be installed on a computer on
which Reporting Server is installed.
ODBC Connects to and retrieves data from ODBC-compliant data sources.
XML Retrieves XML data from any XML web source (such as a web server)
that can be accessed through a URL.
All data-processing extensions that are installed with SSRS (except XML), leverage corre-
sponding .NET data providers. The
Microsoft.ReportingServices.DataExtensions
library
provides wrapper classes that supply SSRS data-processing extension interfaces to .NET
data providers.
Developers can create additional custom data-processing extensions.
Delivery Extensions
Delivery extensions deliver reports to specific devices or formats. Extensions included with
SSRS include email and file share delivery. The delivery method and, therefore, corre-
sponding extension are selected when a user (or an administrator) creates a subscription.
A sample of printer delivery extension is included with SQL Server samples and discussed in
Chapter 26, “Creating and Calling a Custom Assembly from a Report.” Table 2.4 outlines
the delivery extensions included and configured with SSRS.
Developers can create additional custom delivery extensions.
Rendering Extensions
Report Server rendering extensions transform a report’s layout and data into a device-
specific format. Extensions included with SSRS include HTML (3.2 and 4.0), Microsoft
Excel, Microsoft Word, Text/CSV, XML, image (BMP, EMF, GIF, JPEG, PNG, TIFF, WMF),
and PDF rendering.
NOTE
With SSRS, Microsoft added the ability to export to Microsoft Word as a new rendering
extension.
file.
Report Server Databases
The SSRS catalog encompasses two databases: the Report Server database (the default name
is ReportServer) and Report Server temporary database (the default name is
ReportServerTempDB). The Report Server database is a SQL Server database that stores
parts of the SSRS configuration, report definitions, report metadata, report history, cache
policies, snapshots, resources, security settings, encrypted data, scheduling and delivery
data, and extension information.
NOTE
Although users can certainly directly access databases in the SSRS catalog and direct-
ly modify objects that SSRS uses, this is not a recommended (or supported) practice.
Underlying data and structures within the SSRS catalog are not guaranteed to be com-
patible between different releases of SSRS, service packs, or patches.
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
34
CHAPTER 2 Reporting Services 2008 Architecture
Treat the Report Server database as a production database. A loss of snapshot data can
negatively impact a business. For example, users might make some business decisions
using a snapshot’s capabilities to report “frozen-in-time” data.
Another database that SSRS uses is the Report Server temporary database. This database is
responsible for storing intermediate processing products, such as cached reports, and
session and execution data.
NOTE
To store temporary snapshots in the file system, rather than in the database, adminis-
trators should complete the following steps:
1. Modify
RSReportServer.config
and set
events. When the scheduling and delivery processor receives an event, the scheduling and
delivery processor collaborates with the report processor to render a report. After a report
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
35
Report Builder 1.0
2
is rendered, the scheduling and delivery processor uses delivery extensions to deliver a
report.
The scheduling and delivery processor leverages the SQL Server Agent as a scheduling
engine. The schedule is based on the local time of the Report Server that owns the sched-
ule. When an administrator creates a new schedule, the SSRS creates a SQL Server Agent
job to run on the requested schedule. Then SSRS adds a row in the Schedule table of the
Report Server database. The row’s ScheduleId field is the job’s identifier. Administrators
can schedule subscriptions, report history, and snapshot execution.
When the scheduled time comes, the SQL Server Agent generates an event by executing
the scheduled job. The job inserts a row in the Event table of the Report Server database.
This row serves as an event for the scheduling and delivery processor.
The scheduling and delivery processor checks the Event table and initiates appropriate
actions as a response to an event.
NOTE
The polling interval is specified in the
rsreportserver.config
configuration file, and
is set to 10 seconds by default.
The scheduling and delivery process “breaks” when either (or both) the SSRS Windows
service is not running (the scheduling and delivery processor is not processing events) or
the SQL Server Agent is not running (the agent is not generating events).
NOTE
C:\Users\<Username>\AppDation\Local\Apps\2.0\<obfuscated directory>
(Windows 2008).
Before you can use Report Builder
. You must have appropriate permissions, and be a member of the Report Consumer
role or a custom role that includes the Consume Reports task.
. At least one report model has to be published.
. An Internet browser must allow you to download files.
Report Model Designer
The Report Model Designer creates report models for use by Report Builder. A model
abstracts complexities of underlying data. For example, a model allows mapping names of
tables and columns to business terms that an end user can easily understand.
The Report Model Designer is hosted in Business Intelligence Development Studio (BIDS) or
Visual Studio and is intended for use by developers. Actually, BIDS is a Visual Studio shell
with only BI projects and no language projects. One of the BI projects is the Report Model
Project, which launches the Report Model Designer and allows developers to create models.
Report models and, therefore, ad hoc reports can work only with SQL Server data sources:
SQL Server database engine and SQL Server Analysis Services. However, developers can
work around this limitation and access other data sources by using link servers or Analysis
Services Unified Data Model. Both provide a thin layer of abstraction and allow access to
any OLE DB- or ODBC-compliant data source, including Oracle.
Report Builder 2.0
Report Builder 2.0 is very different from Report Builder 1.0. Report Builder 1.0 works
entirely on metadata models generated by Report Model Designer or through Report
Manager. Report Builder 2.0 works directly against defined data sources or shared data
sources. In short, Report Builder 2.0 is a full-featured Report Designer in its own right.
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
37
Report Designer
design that Visual Studio provides for Windows and web applications: You can drag and
drop reporting controls to a report, arrange them as needed, set properties, and establish
associations with data sets that were designed through the Data tab.
The Preview tab provides a preview for a report so that developers can test and adjust the
report as needed.
Report Designer provides the Report Wizard that takes developers through the guided
steps to create a report. The wizard provides a limited number of layouts to choose from,
but a report developer can modify the layout as needed by using the Layout tab after
completing the wizard’s steps.
Finally, Report Designer enables developers to build and deploy reports to SSRS.
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
38
CHAPTER 2 Reporting Services 2008 Architecture
NOTE
Reports developed by Report Designer cannot be interpreted or edited by Report Builder 1.0.
Report Manager
Report Manager is a web-based report access and management tool providing access to a
single instance of a Report Server. Among other things, via Report Manager users can view,
search, and subscribe to reports; manage security (report access and roles); create folders
and move reports around folders; manage data sources; and set report parameters. Security
permissions determine the actions a user can perform using Report Manager. The default
URL that invokes Report Manager is http://<server>/reports. The default directory that
contains the Report Manager’s binaries, pages, and so on is
C:\Program Files\Microsoft
SQL Server\MSRS10.MSSQLSERVER\Reporting Services\ReportManager
.
Although Report Manager provides for limited customization, it is not designed to
support customization. This leaves companies with a few customization options, but these
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
/Reports/Pages/Settings.aspx">
ptg
39
Performance Monitoring Objects
2
TIP
Use SQL Server Management Studio for a consolidated view of an SSRS web farm.
Reporting Services Configuration Tool
The Reporting Services Configuration tool is a Windows Forms application that can be
used to start and stop the Report Server Windows service and reconfigure Report Servers.
For example, administrators can change the Report Server’s database and SQL Server
names, change the SSRS Windows service identity, and change the virtual directories used
to access the Report Server and Report Manager. Administrators can start the Reporting
Services Configuration tool from SQL Server 2005 by selecting Configuration Tools,
Reporting Services Configuration, or from the SQL Server Configuration Manager by click-
ing the Configure button in the SQL Server Reporting Services Properties dialog box.
RSPrintClient Control
The
RSPrintClient
ActiveX control provides client-side printing for reports viewed in
Report Manager. The control presents the Print dialog box for a user to initiate a print job,
preview a report, specify pages to print, and change the margins. Developers can access
this control programmatically in the code to enable report-printing functionality in their
applications.
WMI Provider
SSRS includes a Windows Management Instrumentation (WMI) provider that maps SSRS
XML configuration files to a set of classes to simplify configuration management of the
Report Server and Report Manager, and to minimize configuration errors. The WMI
Command-line utilities Three utilities, designed to assist with scripting of
administrative tasks, installed automatically during
the Reporting Services install.
Data-processing extensions Retrieve report data from a data source. Developers
can develop additional custom data-processing
extensions.
Rendering extensions Transform the report’s intermediate format (a combi-
nation of the report’s layout and data) into a device-
specific format, such as HTML. Developers can
create new rendering extensions.
Delivery extensions Deliver reports to specific devices, such as email or
a file system. Developers can create new delivery
extensions.
Security extensions Enable authentication and authorization of users and
groups. Developers can (excluding SQL Server
Express Edition) create new security extensions.
Report Server database Stores report definitions, report metadata, report
history, cached reports, snapshots, resources, secu-
rity settings, encrypted data, scheduling and delivery
data, and more.
Scheduling and delivery processor Monitors for events (such as timed subscription) and
collaborates with report processor (to render a
report) and delivery extensions (to deliver scheduled
reports to a location specified in the subscription).
Report Manager Provides web-based report access and management
capabilities. The default URL that invokes Report
Manager is http://<server>/reports.
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
TABLE 2.5
Continued
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
This page intentionally left blank
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
CHAPTER
3
Getting Started with
Reporting Services Tools
IN THIS CHAPTER
. Report Manager
. Business Intelligence
Development Studio
. Report Designer
. Report Builder 1.0
. Report Builder 2.0
. Reporting Services
Configuration Manager
. SQL Server Management Studio
S
SRS uses a number of tools to develop and deploy reports,
and to configure the Report Server. These tools include
Report Designer, Business Intelligence Development Studio
(BIDS), and Report Builder 1.0 and 2.0 for report develop-
ment. On the configuration front, you can use the
Reporting Services Configuration tool to configure most
with less access will see different results depending on their level of access.
In case you are thinking about customizing Report Manager, realize that you have limited
customization options. For example, you can modify the application title from within the
Site Settings menu. You can also modify the style sheet to give it a customized look and
feel. Remember to fully test any modification you make as changes may not be covered by
Microsoft support.
Business Intelligence Development Studio
Business Intelligence Development Studio (BIDS) is the Visual Studio 2008 shell with
specific project types related to business intelligence. These project types include
Reporting Services, Analysis Services, and Integration Services.
Reporting Services has two different project types. The first is the Report Server project,
which initiates the Report Designer interface so that we can create reports in BIDS. The
second project type is the Report Model project, which enables us to create semantic
models for use in Report Builder 1.0.
Once a project is open inside of BIDS, four panes are available:
. Solution Explorer
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
45
Business Intelligence Development Studio
3
Designer
Solution
Explorer
Properties
window
Toolbox
FIGURE 3.2
BIDS open with a report project.
BIDS. The other report-authoring tools included in Reporting Services live outside the
Visual Studio/BIDS environment.
Report Designer enables you to do a number of things, including the following:
. Define data sources
. Create queries against the data sources
. Lay out data regions on a report
. Apply data elements to data regions
. Create report parameters
. Apply formatting
. Preview the report
. Publish the report and data sources
Report Designer adds a new window to BIDS in addition to the standard Visual Studio
windows discussed earlier (Solution Explorer, Toolbox, Properties, and Design). The new
window is called Report Data. By default, this window is hidden behind the Toolbox. If it
is not visible, you can make it so via View, Report Data.
Figure 3.3 shows the Report Data window. The Report Data window allows you to not
only manage the data set included in the report, but also to manage embedded images
and report parameters.
The other key item that Report Designer embedded in Visual Studio is the Report menu.
The Report menu enables you to edit report properties, add page headers and footers,
show the ruler, and show the grouping pane.
Report Builder 1.0
Report Builder 1.0 (see Figure 3.4) is largely a throwback to SSRS2K5, with extremely few
changes. It is a click-once smart client application that is launchable either through Report
Manager or via the URL.
Report Builder 1.0 is dependent on metadata report models generated with either BIDS
through report model projects or from Report Manager. Report models enable end users
to navigate through the data while at the same time selecting and choosing what inter-
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
in Report Builder 2.0 can be edited in Report Designer and reopened again in Report
Builder 2.0. Therefore, reports can originate with end users and can be upgraded by soft-
ware developers.
Report Builder 2.0 features a Ribbon, similar to the ones found in Office 2007. This creates
a look similar to some other popular tools used by high-power analysts such as Excel.
Report Builder 2.0 can create tabular, matrix, chart, and even gauge reports and free-form
reports (via the List control). All these report items are available through the Ribbon inter-
face. You can also edit report properties such as the page layout and size. You can also
include subreports and add page headers and footers.
The UI of Report Builder 2.0 is similar to 1.0 in other ways, too. It includes a Data pane in
which you can add and configure report parameters, embedded images, and the data set
included in the report. There is also a grouping pane, which enables you to easily manage
the grouping in the report. It also includes a Properties window, which enables you to edit
properties of the selected item.
Unlike Report Builder 1.0, in which you could only publish a report to the server that
hosted the model, Report Builder 2.0 enables you to publish reports to a Report Server of
your choosing. This is another side effect of reports using “standard” Reporting Services
data sources. Figure 3.5 shows Report Builder 2.0 with all windows displayed.
With all the similarities to Report Designer, there still remains a key difference. Report
Builder 2.0 looks at the RDL file primarily as a document. Report Designer/BIDS includes
multiple RDL files within projects and projects within solutions. This is in keeping with
From the Library of STEPHEN EISEMAN
Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark.
ptg
49
Report Builder 2.0
3
Ribbons
Properties window
Grouping window
ptg
50
CHAPTER 3 Getting Started with Reporting Services Tools
Support for Tablix/Gauge
report items
Yes No Yes
Reporting Services Configuration Manager
Now that we have covered the report-authoring tools, let’s look at the configuration and
management tools.
The first of these you are likely to use is the Reporting Services Configuration Manager.
This tool, as its name suggests, is used to configure Report Server settings. Depending on
the installation parameters, it can be used before the Report Server or it can be used to
verify settings after the Report Server has been installed.
Before using the Reporting Services Configuration Manager, you must do a few things.
First, you must have administrator permissions on the Report Server you are configuring.
If you are using the tool to make or deploy or upgrade the Report Server database, you
should have permissions to create databases on the target SQL server. In addition,
Windows Management Instrumentation (WMI) must be enabled on the Report Server. The
Reporting Services Configuration tool uses WMI to make configuration changes to some
Reporting Services parameters. If you are managing a remote server, make sure remote
WMI access is enabled.
Figure 3.6 shows the Reporting Services Configuration Manager. You can use this tool to
configure a number of items. The sidebar on the left accesses each item, and the pane on
the right allows you to edit them. With this tool, you can configure the following options:
. Services Account: This account runs the Report Server Service. The account has to
be specified during the installation, but can be modified from here.
. Web Service URL: The URL from which to access the Reporting Services web service
endpoints and URL access. Multiple virtual directories can be configured here; Secure
Sockets Layer (SSL) can be configured here, too.
. Report Server Database: This page can be used to create or change a Reporting