Chapter 9. Scheduling

9. Scheduling

ReportServer provides you with the option to schedule reports such that they are executed at a given date or recurring events. For this you can choose any of the familiar export formats. As target you can either specify the email account of a user registered in ReportServer or let the result be stored directly in a TeamSpace.

To schedule a report, first open the report and click on the button schedule in the main toolbar. The opening dialog first asks you to specify a target format and the recipients (selection via double click). If the report is sent via email all the recipients will get a copy. In case the executed report is stored in a TeamSpace, the recipients will be notified of that. The checkbox advanced options uncovers further configuration options on the following pages.

On the next page you are asked to select the target of your schedule entry. This can be a TeamSpace, email recipient, or both. In case the executed report is to be sent as an email attachment, you need to provide a subject and a message for the email. If the report is to be stored in a TeamSpace, please provide the target TeamSpace and a target folder (if no folder is selected, it will be placed directly under the root folder). Under "name" you should provide a file name for the to be created object. Via the ${}-expression language (see Appendix B.) you can provide a dynamic name that contains, for example, a timestamp of the execution ("${now} My Report").

9.1.1. Conditional Scheduling

If you selected display advanced options on the first page, an extra page will be displayed that allows to configure conditions. Whenever the report is scheduled ReportServer will first go through all specified conditions and will execute the report only if all of them pass. In case one of the conditions is not met you can specify if and when ReportServer should try again to execute the report.

Conditions are defined based on parameters specified by an administrator. To add a condition click the add button which will display allows you to select a base parameter from a set of available parameters. In a second step you need to provide a condition based on this parameter. For this you use the syntax of ${}-expressions to write truth values (but without writing the surrounding ${}). To, for example, test if the value "someValue" is bigger than 5 write:

someValue > 5

Alternatively, you can choose one or more conditions from a set of predefined conditions previously defined by an administrator.

Via the selection of "if conditions do not hold" you can specify how ReportServer will handle this case. You can choose between skipping this execution or retrying at a later time. In the first case ReportServer will simply continue with the specified schedule. In case you chose retry you can specify a waiting period after which ReportServer will try again.

The last page in the configuration allows you to configure the schedule specifying when and how often ReportServer will execute the report. The configuration is analogous to the configuration of "recurring appointments" in calendar applications.

9.1.2. Scheduler Module

The scheduler module provides an overview of reports that you scheduled as well as reports that were scheduled for you (i.e., where you have been selected as the recipient). On the left you are given a list of schedule entries which can be filtered using the tools in the above toolbar. If you select an entry, ReportServer will display details in the right half of the window. Besides general information you are given a history of past scheduling events as well as a list of the next five scheduling times.

If you double click on an event, a dialog opens that displays further information for this particular event. In case an error occurred, you will find details here.

Via the detail window's toolbar you can furthermore request an immediate execution of the report as well as editing the configuration. Note that, if you change the configuration, then the old entry will be archived and a new entry is created. This is important if, for example, you'll directly specify the number of executions.

The button load details completes the list of past executions and via delete you can stop an entry and move it to the archive.