Reporting ServicesMicrosoft SQL Server 2008 R2 Part IIAntonios ChatzipavlisSolution Architect - Principal Consultant - SQL Server Evangelist & MVPMCT, MCITP, MCPD, MCSD, MCDBA, MCSA, MCTS, MCAD, MCP, OCA
sp_who1982 >The first contact with computers.1988 > I started my professional carrier in IT, especially in software development.1998 > I earned my 1st Certification as MCSD (3rd in Greece). Since then I certified as MCP, MCSD, MCT, MCDBA, MCAD, MCTS, MCITP, MCPD, MCSA, OCA.1999 > I started my Trainer carrier as MCT. Since then I have more than 14.000 hours of training2010 > I became for first time Microsoft MVP on SQL Server.Leader of IAMCT Europe Greek ChapterModerator of autoexec.grMember of the dotNETZone.gr
Connect with me “ blog” sqlschoolgr@antoniosch .wordpress.com firstname.lastname@example.org http://sqlschool.gr
SSRS Security ModelSSRS is a .NET application.Use Role-based authorization.During installation, sets up the local administrator poolwith the System Administrator and Content Managerroles.SecurablesFolder, Report, Model, Resources, Shared Data Sources
How Role Assignments WorkTasksA set of underlying permissionsSSRS comes with 25 different tasks.Item-level tasksTasks level that acts on an item in the Report Server catalog, such as folders, models,reports, and resourcesSystem-level tasksTasks level that can be performed on objects that are not in the catalog but areglobal in scope, such as site settings and shared data sources.
SSRS PoliciesIs the relationship between items that need to besecured, roles, and users.Is responsible for mapping out the minimum set ofpermissions required for securing a report item.Individual policy is a mapping of users or groups(principals) with a required role needed for access.Each item in the catalog can have multiple policiesdefined; however, no single item can have two policiesthat apply to the same principal.
Built-In RolesSystem Level Item Level RolesRoles BrowserSystem Administrator Content ManagerSystem user Report Builder My Reports Publisher
Report Execution and ProcessingRetrieves the report definitionData processingLayout processingRendering
Report-Execution TimeoutsReport Execution Query TimeoutIs the amount of time a report can take Specify how long an individual queryto process. This value is specified at a can take to come back from the datasystem level, and can be overridden for source. This value is specified insideindividual reports. To set this the reports, by specifying the timeoutsetting, click the Site Settings tab and property while creating a data set.modify the Report Execution Timeout Query timeouts can also apply to data-property. The default value is 1800 driven subscriptions.seconds. SSRS evaluates the executiontimeout for running jobs every 60seconds.
Running Processes aka JobsUser Jobs System JobsRunning an on-demand report Processing a data-driven subscriptionRendering a report from a snapshot Scheduling a generation of a snapshotGenerating a new snapshot Scheduling report executionProcessing a subscription SSRS comes by every 60 seconds and checks on the status of any in progress jobs. Canceling a running job does not guarantee that a query has stopped processing on the remote data server. The property RunningRequestsDbCycle in the RSReportServer.config file sets how often the Report Server evaluates running jobs.
Report-Execution HistoryIn these days of endless audits, SOX (Sarbanes-Oxley), and now PCI (Payment Card Industry), it isbecoming essential to know when someone withinan organization accesses data.It is also helpful to know this information from anorganizational and planning perspective.As more and more reports get published, howoften reports get looked at and by whom could beessential information.
SSRS Execution Log• Name of the physical machine that ran the report (Report Server, not database server)• Unique ID of the report• Unique ID of the user running the report• Whether the request came from a user or system process• What rendering format was used• Values of the report parameters• When the report process started and when it finished• Amount of time the server took to process the report in milliseconds• Type of data used for execution (live, cached, snapshot, history)• Final status code of the report processing (success or first error code)• Final size of the rendered report in bytes• Number of rows returned in the data sets of the rendered reports
What is a SubscriptionSubscription setting up a job on the ReportServer to deliver a report to a user at aspecified point in time without the useractively going to the Report Server andrunning the report.
Subscription FundamentalsUser must have access to view the report.User must have a role assignment that includes the task Manage IndividualSubscriptions before subscribe to the report.The report has to be able to run independently, that is, the data sources must useeither stored credentials or no credentials.The report must have a configured delivery method. The built-in ones include emailand file sharing.You must specify a rendering extension for the subscribed report.Some trigger or event is required to run the subscription. Usually, this is a scheduledevent, based on either a custom or shared schedule.The parameter values for any parameter in a report must be specified or defaulted.
Uses of SubscriptionsDeliver reports to end users.Save reports for offline viewingSend long-running reports or large reportsdirectly to disk.Preload the Report Server’s cache.
Standard vs Data-DrivenSubscriptionsStandard Data-DrivenUsers can create and manage standard The data used for the subscriptionsubscriptions for themselves. must come from a query.All the information for the subscriptionis static, which means that the The list of recipients is derived via ainformation has to be specified when query.the subscription is created (and that theinformation cannot be modified at Users can create customized reportsruntime). for recipients based on preferences of that recipient or that recipient’s role within the organization. Even the delivery style and location can be customized.
Managing & MonitoringSubscriptions can be managed with Report Manager.Report subscriptions are managed just like any otherproperty of a report.The Status column is crucial for monitoring the executionof a subscription in case the subscription runs into aprocessing error.
Key ManagementBacking Up the Symmetric Keyrskeymgmt -e -f rsdbkey.snk -p<password>Restoring the Symmetric Keyrskeymgmt -a -f rsdbkey.snk -p<password>Changing the Symmetric Keyrskeymgmt –sDeleting the Symmetric Keyrskeymgmt -d