Lesson 5: Parameters

Parameters provide a means to set a value to a named Parameter and use the name through out your configuration. This makes it possible to change the value once and have it applied whenever the Parameter is used (at run time).  Dependencies make sure objects run when certain conditions have been satisfied other than the scheduled date and time.

Parameters and Parameter Groups

Parameters are created on the Parameter Properties window. You can create any number of Parameters and assign values to them. Optionally, you can add Parameters to a Parameter Group. You don't have to use Parameter Groups, but you may want to if you have a large number of Parameters and you want to tell the Executive Server which Parameters to use for certain objects. When setting up an Operations, Steps or Jobs you can specify a Parameter Group of <all>, <none> or a specific group you have created. If you specify <all>, the Executive Server will process all Parameter added to the database without regard to any Parameter Groups. If you specify <none>, the Executive Server knows not to perform any Parameter substitution. Choosing a specific Parameter Group tells the Executive Server to just apply the Parameters from that group.

Parameter Substitution

When you have a Parameter Group assigned at multiple levels (that is, to an Operation that exists in a Step and further a Step in a Job), the Parameter Group assigned to an Operation is applied first, then the Step and last the Jobs. You can assign a Parameter Group at the Job level and have it applied throughout to all Steps in the Job and Operations in the Steps. You can provide additional Parameters or override the Job level Parameters by supplying a different Parameter Group for Steps or Operations. If you supply the same Parameter Group at different levels (e.g., Operation and Step have the same list), the extra processing of Parameter substitution will occur but the net result will be the same. The Executive Server does the Parameter replace right before an Operation is to be processed. It simply replaces the Parameter Name with its value.

The following example shows a Parameter used to contain a file directory:

Parameter Name: @MyFolder

Parameter Value: c:\mybat\stuff

Example  

The Operation might be:

Notepad @MyFolder\myfile.txt

When the Operation is run by the Executive Server, the Executive Server will run

Notepad c:\mybat\stuff\myfile.txt

This will cause Notepad.exe to be run with c:\mybat\stuff\myfile.txt as the input file.

Step 1: Creating Parameters

1.Right-click on the Parameters node in the tree view and select the New Parameters menu item. The Parameter Properties window is displayed.  

2.Enter the Parameter Name, Description and Value.

3.Select the Add button to add the Parameter.

4.You can now add the Parameter to a Parameter Group by displaying the Parameter Group List window and then the Parameter Group Update window.

5.Select the Parameter in the Parameters list and

6.Use the right arrow button to copy the Parameter to the Parameter Group list.

Do this for each Parameter you want in the Parameter Group.

Step 2: Creating Parameter Groups

Once you have created parameters as shown in Step 1, you can create a Parameter Group.

1.Right-click the Parameter Groups node in the tree view and select the New Parameter Groups menu item.  The Parameter Group Properties window is displayed.  

2.Enter in a Name, Description and add at least one Parameter from the Parameters list to the Parameters in this Parameter Group list.