Download presentation
Presentation is loading. Please wait.
Published byBrian Owens Modified over 8 years ago
1
DAT 354: Building SQL Server Reporting Services Applications Brian Welcker Group Program Manager SQL Server Reporting Services Microsoft Corporation
2
Goals Present opportunities for embedding Reporting Services in applications Review programmatic access to Reporting Services platform Preview Report Controls available in Visual Studio 2005 and SQL Server 2005 Prerequisite: Understanding Reporting Services
3
Reporting Platform Integration.NET-based solutions (non-reporting) with reporting needs Report Authoring and Publishing Tools Delivery, Data and Rendering Extensions (Add-ons) Server Management Applications Portals and Collaboration Applications
4
SQL Server Catalog Report Server URL / XML Web Service Interface Report Processing Delivery Delivery Targets (E-mail, File Share, Custom) Rendering Output Formats (HTML, Excel, PDF, Custom) Data Processing Data Sources (SQL, OLE DB, XML/A, ODBC, Oracle, Custom) Security Security Services (Windows, Custom) Office Custom Application Browser Report Server Architecture
5
Programmatic Interfaces Customizable XML report definition Open Schema Viewing Interfaces URL Addressability Web Service / SOAP Management Interfaces Web Service / SOAP WMI Interface Extension Interfaces Data, Delivery, Rendering and Security
6
Generating Reports Application specific report authoring requirements Reports are defined in Report Definition Language (RDL), a customizable XML format Use.NET XML classes to generate report definitions Leverage RDL Schema Description (XSD)
7
Report Generation
8
URL Addressability Embed or link to reports via the Report Server URL http://[servername]/ReportServer Supports both GET and POST (avoids parameter values on URLs) Can returns any output in any format Optional HTML Viewer for parameter prompting and navigation Fully localized - based on language in HTTP header
9
URL Addressability
10
URL Parameter Directives Report Parameters Parameter names must match report definition Example: http://servername/ReportServer/ReportName? CategoryID=1&EmployeeID=1 User Credentials (dsu: and dsp:) Credentials for each report data set Example:https://servername/ReportServer/ReportName? dsu:DataSet1=MyUserName& dsp:DataSet1=MyPassword Use Secure Protocols! (HTTPS POST)
11
URL Parameter Directives Report Server Parameters (rs:) Name/Value pairs specifying server behavior Same for all Rendering Extensions Example: http://servername/ReportServer/ReportName? rs:ClearSession=True Rendering Device Info (rc:) Name/Value pairs specifying behavior specific to the format being rendered to (i.e., FindString, Section, Zoom, etc.) Unique per Rendering Extension Example: http://servername/ReportServer/ReportName? rc:Section=7&rc:HTMLFragment=true
12
Web Service Interfaces Namespace Management Item Properties Report Execution Report Parameters Report History Data Source Management Scheduling Subscriptions and Delivery Linked Reports Job Management Security Management
13
Getting Started Add Web Reference to your VS project http://[servername]/ReportServer/Reportservice.asmx Proxy generated by VS Complex types defined in WSDL Synchronous and asynchronous support Update operations may be batched SOAP Headers Session ID Server Info Batch ID
14
Getting Started Web Service - Authentication Basic Authentication System.Net.NetworkCredentials Dim rs As New MyServer. RSWebService() ‘ Prompt user for credentials rs.Credentials = new System.Net.NetworkCredential ("user", "pwd", "domain") Integrated Authentication System.Net.CredentialCache Dim rs As New MyServer. RSWebService() rs.Credentials = System.Net.CredentialCache.DefaultCredentials
15
Web Service Client Application
16
Server Extensibility Extensions provide a way to extend the Reporting Services platform Managed code runs in server process Published CLR interfaces Extension Types Data Extensions - Communicates to data sources and returns data Delivery Extensions - Delivers reports over different protocols and to different devices Rendering Extensions - Renders to specific formats and devices Security Extensions - Authenticates and authorizes non-Windows users Extending should be your last resort!
17
Data Extensions Input: connection information, query (optionally support parameters) Output: result set Subset of the.NET Managed Data Provider Interface (system.data) Any.NET managed provider will just work Required: IDbConnection, IDbCommand, IDataParameter, IDataReader Optional: Extended Data Extension interfaces Generic query designer in Report Designer
18
Rendering Extensions Input: a processed report object model Output: format-specific output stream IRenderingExtension Interface Render method responsible for primary output stream RenderStream method responsible for returning ancillary streams (images, etc.) GetRenderingResource may be used to provide non-report specific content Proceed with caution: Rendering Extensions are difficult to write and maintain
19
Delivery Extensions Input: event and specified destination Output: delivered reports or notifications IDeliveryExtension Interface Deliver method delivers a input notification to a destination ValidateUserData method verifies that a set of delivery information is valid ExtensionSettings property allows delivery extension to be self describing Can also provide UI to integrate with Report Manager
20
Security Extensions Input: user credentials, security policies Output: authenticate user credentials and authorize server operations IAuthentication Interface LogonUser method authenticates the user GetUserInfo retrieves a user’s unique identity IAuthorization Interface Provides classes, enumerations, methods for authorizing the user Allows creating, verifying security descriptors Documented as a White Paper Only available in Enterprise Edition
21
Report Controls SQL Server 2005 and Visual Studio 2005 will include WinForms and ASP.NET report controls Controls make it easy to embed Reporting Services functionality in applications Controls work in both standalone and Report Server modes Freely redistributable in custom applications
22
ASP.NET Control
23
Control Report Server Mode Report is published to Report Server Control uses web service to talk to server Data is retrieved and report is processed on server Report snapshot (WinForms) or HTML (ASP.NET) is sent back to control Full set of events provided (next page, previous page, etc.)
24
WinForms Control
25
Control Standalone Mode Report creation is integrated with language project Build report from project data sources (XSD) Report is compiled into application or stored on disk At runtime, application passes report, parameter values, and data to control Full set of events provided (next page, previous page, etc.)
26
Summary Leveraging SQL Server Reporting Services in your applications… provides rich data visualization lets you focus on business value, not reporting infrastructure is easy via URL Access and Web Services is even easier using the report controls in Visual Studio 2005 and SQL Server 2005
27
Additional Resources Reporting Services web site http://www.microsoft.com/sql/reporting Reporting Services newsgroup news:microsoft.public.sqlserver.reportingsvcs Course 2030: Creating Reporting Solutions http://www.microsoft.com/traincert/syllabi/2030AFin al.asp http://www.microsoft.com/traincert/syllabi/2030AFin al.asp SQL Server Community Sites http://www.microsoft.com/sql/community/
28
Q1:Overall satisfaction with the session Q2:Usefulness of the information Q3:Presenter’s knowledge of the subject Q4:Presenter’s presentation skills Q5:Effectiveness of the presentation Please fill out a session evaluation on CommNet
29
© 2004 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.