WebFOCUS Online Help > ReportCaster Development and Administration > Creating and Maintaining a Schedule > Creating a Task
In this section: |
When creating a schedule, you must create a Task to be distributed by ReportCaster. If you are distributing scheduled output using the e-mail or printer distribution methods, you can create multiple Tasks within a single schedule. In such a schedule, you can clone (duplicate) an existing task to use as a template for new tasks.
ReportCaster Administrators specify which types of Tasks appear in the Tasks tab using the Schedule Task setting in the ReportCaster Server Configuration tool (for more information, see Specifying Schedule Task Settings). By default, you can create the following types of Tasks:
The options for creating a Task differ depending on the Task type. For more information about these options, see the specific procedure for each Task type.
When creating a Task, you can specify to burst a report. Bursting enables you to target relevant sections of a report to individual users. Each section is saved as a separate file. The WF Server Procedure, Standard Report, and My Report Task Types support bursting.
If you are distributing a burst tabular report, the burst value is determined by the first BY field. If you are distributing a burst graph report, the burst value is determined by the second BY field. The burst value is automatically determined by the internal matrix of the WebFOCUS Reporting Server. The internal matrix is a memory area that stores each database field value and calculates values referenced by the TABLE or GRAPH request.
When a report is burst, all data values generated for each burst section are returned to the ReportCaster Distribution Server.
The following are guidelines and limitations that apply to the ReportCaster burst feature:
[wildcard]:abc* = all values that start with ‘abc’.
[wildcard]:a?c = all three-character values that start with ‘a’ and end with ‘c’.
[wildcard]:a?c* = all values that start with ‘a’ and have a ‘c’ as the third character.
[regexp]:[bcr]at = values that are bat, cat, or rat.
[regexp]:[[^bcr]at = any value that is not bat, cat, or rat.
[elsesend]: = reports for burst values not contained in the Distribution List will be sent to the named recipient.
The following are example entries in an e‑mail distribution list that illustrate the use of the wildcard and default distribution keywords in burst values.
Burst Value |
Address |
---|---|
[wildcard]:*an* |
sml@company.com |
England |
ray@company.com |
[elsesend]: |
jt@company.com |
Using a scenario where the report is burst on the Country field that contains values of Germany, USA, France, Canada, Italy, Chile, England, and Japan, then:
ON primarysortfield SUBHEAD
Note: For additional considerations when using WebFOCUS commands with burst reports, see Tips and Techniques for Coding a ReportCaster Report.
The New Task - ReportCaster window opens with a Task Type of WF Server Procedure, as shown in the following image.
If this field is grayed out, it means that a default Execution ID and password have been specified within the ReportCaster Server Configuration tool.
If the Execution ID field is not grayed out, and you will be using an Execution ID that you previously used for a Task on the selected server, you can select the Execution ID (for example, rcadmin) from the drop-down list, shown in the following image.
If the Execution ID field is not grayed out and you will be using a new Execution ID, perform the following steps:
Note: The Execution ID is added to the ReportCaster Repository and is viewable in the ReportCaster Console.
The Select WF Server Procedure window opens, as shown in the following image.
When a WebFOCUS Reporting Server is Application Enabled, you will see a node called Applications. When you open the Applications node, a query is made to the server to retrieve a list of applications found under its Application Root (APPROOT) directory. When you open an application (for example, ibinccen), a request is issued to the server to get the list of accessible files in the application, as shown in the following image.
Note: When a WebFOCUS Reporting Server is configured with the traditional Cataloged Path (EDAPATH) setting, you will see Applications and Cataloged Path nodes listed under the server. For more information about these concepts, see Data Servers Feature in the WebFOCUS Managed Reporting Developer's Manual.
Use the following guidelines when selecting a format:
ReportCaster Administrators can specify which report formats will appear in the Tasks tab through the Schedule Format setting in the ReportCaster Server Configuration tool, as described in Specifying Schedule Format Settings).
For detailed information about each format, see ReportCaster Formats for Scheduled Output.
The new task is listed with the Task ID, Name, Type of procedure, and Scheduling Object (procedure name), as shown in the following image.
A duplicate of the selected task appears in the list with the name “Clone Of taskname”.
Open the cloned task and modify as needed.
Note: If
you have multiple Tasks, you can move the position of a Task within
the window by clicking the following up or down arrows.
Note: You cannot create a WF Server Procedure schedule when a server within a cluster configuration is unavailable.
A Managed Reporting task includes either a Standard Report or a My Report. The options for creating a task using either of these reports are the same. To explain the Managed Reporting Task options, this procedure uses a Standard Report as the example.
If this field is grayed out, it means that a default Execution ID and password have been specified in the ReportCaster Server Configuration tool.
If the Execution ID field is not grayed out, and you will be using an Execution ID that you previously used for a Task, you can select the Execution ID (for example, rcadmin) from the drop-down list, shown in the following image.
If the Execution ID field is not grayed out, and you will be using a new Execution ID, perform the following steps:
Note: The Execution ID is added to the ReportCaster Repository and is viewable in the ReportCaster Console.
The Alert Schedule dialog box opens, as shown in the following image.
Select one of the following options:
Caution: An alert schedule distributes e-mails to your mail server more frequently than expected when the schedule interval is less than the time it takes to run the procedure and the Delay option is selected. Be sure to set the schedule interval to a time period greater than the time it takes to run the scheduled procedure.
Click OK to return to the Tasks tab.
Use the following guidelines when selecting a format:
ReportCaster Administrators can specify which report formats will appear in the Tasks tab through the Schedule Format setting in the ReportCaster Server Configuration tool, as described in Specifying Schedule Format Settings).
For detailed information about each format, see ReportCaster Formats for Scheduled Output.
Note: When you distribute a Standard Report or My Report to the Library, by default, the report is placed in a category named with the Managed Reporting domain name of the report.
The task is listed with the Task ID, Name, Type of procedure, and Scheduling Object (procedure name), as shown in the following image.
A duplicate of the selected task appears in the list with the name “Clone Of taskname”.
Open the cloned task and modify, as needed.
Note: If
you have multiple Tasks, you can move the position of a Task within
the window by clicking the following up or down arrows.
Note: Reporting Objects that have the "Show as Standard Report" or "Show Only as Standard Report" property selected appear as Standard Reports. However, these Reporting Objects cannot be scheduled by ReportCaster.
Note that you can also specify parameter names and associated values using the following format:
www.address.com?¶meter1_name=parameter1_value¶meter2_name=parameter2_value
The maximum length of this field is 1200 characters.
Note:
Remove - Removes the selected row.
Insert Above - A new row appears above where your cursor is positioned.
Insert Below - A new row appears below where your cursor is positioned.
If you are positioned on the last row and you press the Enter key, you will be returned to the first row. To insert a new row, right-click and then select Insert Below or Insert Above.
The task is listed with the Task ID, Name, Type, and Scheduling Object, as shown in the following image.
A duplicate of the selected task appears in the list with the name “Clone Of taskname”.
Open the cloned task and modify as needed.
Note: If you have multiple Tasks,
you can move the position of a Task within the window by clicking
the following up or down arrows.
Note: If a schedule has multiple tasks and one of the tasks fails, then the file will not be deleted. This is true even when the file is distributed successfully.
A duplicate of the selected task appears in the list with the name “Clone Of taskname”.
Open the cloned task and modify as needed.
Note: If you have multiple Tasks,
you can move the position of a Task within the window by clicking
the following up or down arrows.
To create an FTP task:
Note: If a schedule has multiple tasks and one of the tasks fails, then the file will not be deleted. This is true even when the file is distributed successfully.
A duplicate of the selected task appears in the list with the name “Clone Of taskname”.
Open the cloned task and modify as needed.
Note: If
you have multiple Tasks, you can move the position of a Task within
the window by clicking the following up or down arrows.
If the Task (WF Server Procedure, Standard Report, My Report, and URL only) you are creating has parameters, you can use the optional Advanced Task Options tab to specify parameter values. You can also use the Advanced Task Options tab to schedule a maximum of two pre- and post-processing procedures (WF Server Procedure, Standard Report, and My Report Tasks only). Pre- and post-processing procedures are non-reporting Tasks to be performed in support of the report. For example, a report procedure may have associated procedures that set up and clean up the environment. These procedures must be located on, and be accessible to, the WebFOCUS Reporting Server during execution of the scheduled job. If the pre- and post-processing procedure contains a TABLE or GRAPH request, it must contain a HOLD or SAVE statement so that the data will not be sent back to the ReportCaster Distribution Server.
Perform the following steps to specify parameter values for a Task:
If you are scheduling a WF Server Procedure, Standard Report, or My Report Task, the parameter name/description(s) are populated automatically, and you only need to specify the parameter value(s). For a URL Task, you must specify both the parameter name and value; this is documented in How to Create a URL Task.
Note: For more information about specifying parameter values for a procedure, see Considerations When Specifying Parameter Values.
The following are considerations when specifying parameter values for a procedure:
Note:
As an alternate method of creating a dynamic selectable list of parameter values, you can use the schedule technique in the HTML Composer (formerly known as HTML Layout Painter). For details, see Technical Memo 4626: Adding Schedule Capability to the HTML Layout Painter.
If you are specifying the entire WHERE condition as the parameter value, you must enclose the value within two single quotation marks rather than a double quotation mark. For example: ''WHERE CAR NOT LIKE MOTO%''
If you are only specifying a value as the parameter value, you do not need to enclose the parameter value within quotation marks. For example: O&DINFO
Note: You can only schedule saved procedures using ReportCaster; HTML forms cannot be scheduled using ReportCaster. Parameter prompting is not available in pre- or post-processing procedures. For more information about WebFOCUS auto prompting, see Coding a User Interface in the Developing Reporting Applications manual.
The following are examples of how ReportCaster displays default variable values, as well as static and dynamic single-select and multi-select lists.
Tip: Since ReportCaster requires considerations for special characters, Information Builders recommends using the syntax specified in the following examples.
The following procedure sets a default value of NY for the STATE (2-3 letters for US State) field, and a default value of Web Sales for the SNAME (Store Name) field. Note that there must be an ampersand in front of the field name in the -DEFAULT command for the amper variable(s) to contain a default attribute in ReportCaster.
-DEFAULT &STATE=NY -DEFAULT &SNAME=Web Sales TABLE FILE CENTORD SUM QTY_IN_STOCK BY STATE BY SNAME BY PRODNAME ON TABLE SUBHEAD "Inventory Report" WHERE STATE EQ '&STATE.2-3 letters for US State.' WHERE SNAME EQ '&SNAME.Store Name.' END
The parameters for this procedure appear as follows in the ReportCaster Scheduler. Note that a default parameter value of NY is displayed for the STATE field, and a default parameter value of Web Sales is displayed for the SNAME field.
The following procedure provides a list of static values that are valid for the SNAME (Store Name) field.
-DEFAULT &STATE=NY TABLE FILE CENTORD SUM QTY_IN_STOCK BY STATE BY SNAME BY PRODNAME ON TABLE SUBHEAD "Inventory Report" WHERE STATE EQ '&STATE.2-3 letters for US State.' WHERE SNAME EQ '&SNAME.(eMart,TV City,Web Sales).Store Name.' END
The parameter values for the Store Name parameter appear as follows in the ReportCaster Scheduler. You can select only one value from the drop-down list.
The following procedure provides a list of values that are valid for the PRODNAME (Product Name) field. This list is dynamically populated with values from the CENTORD data source.
-DEFAULT &STATE=NY TABLE FILE CENTORD SUM QTY_IN_STOCK BY STATE BY SNAME BY PRODNAME ON TABLE SUBHEAD "Inventory Report" WHERE STATE EQ '&STATE.2-3 letters for US State.' WHERE SNAME EQ '&SNAME.(eMart,TV City,Web Sales).Store Name.' WHERE PRODNAME EQ '&PRODNAME.(FIND PRODNAME IN CENTORD).Product Name.' END
The parameter values for the Product Name parameter appear as follows in the ReportCaster Scheduler. You can select only one value from the list.
The following procedure provides a list of static values that are valid for the SNAME (Store Name) field.
-DEFAULT &STATE=NY TABLE FILE CENTORD SUM QTY_IN_STOCK BY STATE BY SNAME BY PRODNAME ON TABLE SUBHEAD "Inventory Report" WHERE STATE EQ '&STATE.2-3 letters for US State.' WHERE SNAME EQ &SNAME.(OR(eMart,TV City,Web Sales)).Store Name. END
The parameter values for the Store Name parameter appear as follows in the ReportCaster Scheduler. You can select more than one value from the list, as shown in the following image. You can also Select All to include every parameter value.
The following procedure provides a list of values that are valid for the PRODNAME (Product Name) field. This list is dynamically populated with values from the CENTORD data source.
-DEFAULT &STATE=NY -DEFAULT &SNAME='TV City' -DEFAULT &PRODNAME='''120 VHS-C Camcorder 40 X''' TABLE FILE CENTORD SUM QTY_IN_STOCK BY STATE BY SNAME BY PRODNAME ON TABLE SUBHEAD "Inventory Report" WHERE STATE EQ '&STATE.2-3 letters for US State.' WHERE SNAME EQ &SNAME.(OR(eMart,TV City,Web Sales)).Store Name. WHERE PRODNAME EQ &PRODNAME.(OR(FIND PRODNAME IN CENTORD)).Product Name. END
The parameter values for the Product Name parameter appear as follows in the ReportCaster Scheduler. You can select more than one value from the list, as shown in the following image. You can also select No Selection if you do not want to perform any data selection test on that field.
Important: When coding a dynamic multi-select list of parameter values using -DEFAULT syntax without storing parameter values in the ReportCaster Repository, the -DEFAULT value is used as specified in the procedure, and the scheduled request will fail if you do not specify three single quotation marks before and after the parameter value string.
To create a new parameter for a task:
The Advanced Task Options window opens displaying the contents of the Parameters tab.
In the Advanced Task Options window, a highlighted new blank line appears in the parameters list and Parameter Properties fields appear at the bottom of the window, as shown in the following image.
Note: An asterisk next to a parameter in the parameters list indicates that it was manually created.
As you type, the Name/Description field in the parameters list reflects your entry.
As you type, the Value field in the parameters list reflects your entry.
The following images shows the typed entries in the Parameters Properties fields reflected in the parameter list.
The new parameter is created and the Advanced Task Options window closes.
You can only delete manually created parameters. These parameters are indicated by an asterisk next to the name. To delete a manually created parameter:
The parameter is deleted and the Advanced Task Options window closes.
If you are scheduling a report Task (WF Server Procedure, Standard Report, or My Report), you can schedule a maximum of two pre- and post-processing procedures. Perform the following steps to schedule pre- and post-processing procedures for a Task:
First. Type the name of the first pre-processing procedure (omit the file extension). ReportCaster will run this procedure immediately preceding the scheduled Task.
Second. Type the name of the second pre-processing procedure (omit the file extension). ReportCaster will run this procedure immediately after the first pre-processing procedure, but before the scheduled Task.
First. Type the name of the first post-processing procedure (omit the file extension). ReportCaster will run this procedure immediately following the scheduled Task.
Second. Type the name of the second post-processing procedure (omit the file extension). ReportCaster will run this procedure immediately after the first post-processing procedure.
Note: For information about specifying parameter values in a pre- or post-processing procedure, see Specifying a Parameter Value in a Pre-Processing Procedure.
The following examples show how to use parameters in pre‑processing procedures.
This example shows how to specify a parameter value in a pre-processing procedure. The following code represents the pre-processing procedure, CARPROFIT, that will be scheduled by ReportCaster. This procedure computes your company growth rate by country. The growth rate is computed based on the parameter value you specify for RATE.
DEFINE FILE CAR PROFIT/D12.2 = RCOST-DCOST; RATE/D5.2=&RATE - 1; END TABLE FILE CAR SUM PROFIT FST.RATE COMPUTE GROWTH/D12.2 = (PROFIT * &RATE); BY COUNTRY ON TABLE HOLD AS CARPROFIT FORMAT FOCUS INDEX COUNTRY END
The following code represents the primary WebFOCUS Reporting Server procedure, CARJOINPROFIT, that will be scheduled by ReportCaster. This procedure joins the CAR and CARPROFIT tables and computes sales by country based on the growth rate in CARPROFIT.
JOIN COUNTRY IN CAR TO COUNTRY IN CARPROFIT TABLE FILE CAR HEADING "Growth Forecast using rate: <RATE " SUM SALES BY COUNTRY ON COUNTRY SUBFOOT "Profit is <PROFIT>" "Growth Forecasted is <GROWTH>" END
When scheduling the CARJOINPROFIT procedure, specify the name of the pre-processing procedure (for example, CARPROFIT) and the parameter value (for example, RATE=1.05).
Note:
When the pre-processing procedure and the primary procedure run, the following information appears in the log report indicating that both procedures ran successfully.
When specifying a pre-processing procedure in ReportCaster, the format for passing an internal variable value is
filename variable=&variable
where:
Is the file name of the pre-processing procedure, excluding the file name extension.
Is the ReportCaster internal variable, for example, DSTOWNER.
The following sample image shows how to pass an internal variable value in ReportCaster.
WebFOCUS |