Previous Topic: SAVEOUTPUT Statement—Specify Whether to Save Output from an Oracle E-Business Suite JobNext Topic: SEARCHRANGE Statement—Specify the Range to be Searched


SCRIPTNAME Statement—Specify a UNIX Shell Script to Run

The SCRIPTNAME statement specifies the UNIX shell script to run.

Supported Job Type

To run shell scripts, this statement is required for the UNIX job type.

Note: All UNIX job definitions require a SCRIPTNAME statement or a CMDNAME statement. Use the SCRIPTNAME statement to run shell scripts and the CMDNAME statement to run binary files.

Syntax

This statement has the following format:

SCRIPTNAME script_name
script_name

Specifies the full path and name of the script to run. It must be a valid executable UNIX file written in a valid scripting language.

Limits: Up to 100 characters; case-sensitive

Notes:

Example: Run a Script Using the Agent

This example runs the sort script on the UNIX_LA agent. The SHELL statement is unspecified, so the shell is picked up from either the first line of the script, the agentparm.txt file, or the user default shell in the user profile.

AGENT UNIX_LA
SCRIPTNAME /mfg/test/sort

Example: Specify a Shell to Run the Script

This example uses the C shell to run the sort script:

AGENT UNIX_LA
SCRIPTNAME /mfg/test/sort
SHELL /bin/csh

Example: Run a Script that is Located in a Path Set in the PATH System Environment Variable

In this example, an agent named UNIXAGENT runs a script named procscript.sh. The job runs under the user ID jsmith, which has the authority to run the script. The path to procscript.sh is set in the PATH system environment variable for jsmith on the agent computer and the agent is configured to search for paths to command and script files.

AGENT UNIXAGENT
SCRIPTNAME procscript.sh
USER jsmith

Example: Run a Script that is Located in a Path Set in a User Environment Variable

In this example, an agent named UNIXAGENT runs a script named myscript.sh. The job runs under the user ID jsmith, which has the authority to run the script. The path to myscript.sh is set in the user environment variable $MY_PATH, which is defined in the profile file for jsmith, and the agent is configured to search for paths to command and script files.

AGENT UNIXAGENT
SCRIPTNAME $MY_PATH/myscript.sh
USER jsmith