Operation Preview

 

Operation

You enter the Operation into this field. An Operation is any program that you want to run (such as an .exe file, .bat script or windows scripting host .vbs). The Operation can have Parameters that will be replaced when processed by the Executive Server. Example Operations:

Example 1:

Start notepad.exe with the file myfile.txt. @path is a Parameter that specifies the path:

Operation: notepad.exe @path\myfile.txt

Example 2:

Start SQL Server's interactive SQL program using c:\test.sql as input and log to c:\applog.dat:
Operation: isql /SMyServ /Pmypass /ic:\test.sql /oc:\applog.dat

Example 3:

Start a Windows command prompt and have it run a .bat file called d:\batch\nightly.bat:

Operation: cmd.exe /c d:\batch\nightly.bat
or just:
d:\batch\nightly.bat 

Parameter

A Parameter Group identifies a set of parameters that can be assigned to an Operation, Step or Job. If you don't want to use a specific Parameter Group and want all Parameters to be used for the object use a Parameter Group of <all>. Parameters are replaced with their value when processed by the Executive Server. Parameters are added to a Parameter Group on the Parameter Group Properties window. Parameters are maintained on the Parameter Properties window.

Buttons

Run Local

Causes the Operation to be run directly from the SmartBatch 2009 desktop as the logged on user. If it does not run as expected, examine the Operation for errors. Make sure you apply any required Parameter Group before you try running the Operation. Check reasons for Operations failing and error codes if the Operation fails to run.

Use the Run Thru Es button to test your Operations ability to run when it is processed by the Executive Server.

Run Thru ES Button

Causes the Operation to be run on demand via the Executive Server. If it does not run as expect, examine the Operation for errors. Make sure you apply any required Parameter Group before you try running the Operation. Check reasons for Operations failing and error codes if the Operation fails to run.

Apply Button

Substitutes the Parameter Group parameters with their values in the Operation.

Reset Button

Replaces the Operation field with the Operation field on the Operation Properties window.

Modify Button

Causes the information for the Operation, including the values on the Operation Properties window, to be saved to the database.

 

To make sure an Operation is setup correctly, you can use the Operation Preview capability. Select the Preview button from the Operation Properties window  to display the following Operation Preview dialog.

The following picture shows the Operation Preview window. You can click on "hot spot" areas in the picture below to get detailed information about buttons, controls and fields.  

Apply any necessary Parameter Group to the Operation and then Run the Operation. If the Operation runs successfully, you have configured it correctly. Otherwise, examine the Operation and make the necessary changes.

 

Note: The Operation is run on the local computer (that is, the computer the Administrator is running on) when the Run Local button is selected. If you need to test or preview the Operation on the computer where the Executive Server (ES) will run, use the Run Thru ES button. The Run Thru ES button executes the Operation on demand. You can view the status of the Operation in the Status list view.  If the Operation runs through the Run Local button but does not run when scheduled on demand (Run Thru ES button), refer to Frequently Asked Questions or Operation Failed for more information.