SQL/MX Guide to Stored Procedures in Java (G06.24+, H06.03+)

Getting Started
HP NonStop SQL/MX Guide to Stored Procedures in Java523727-004
2-24
Setting the CLASSPATH Environment Variable
Setting the CLASSPATH Environment Variable
Use the CLASSPATH environment variable to set the class path in an SPJ
environment for a session in which applications that call or create SPJs run. Set the
CLASSPATH environment variable in either the OSS or Guardian environment,
depending on where you run applications that issue CALL or CREATE PROCEDURE
statements.
Scope of the CLASSPATH Environment Variable
The setting of the CLASSPATH environment variable persists for the current OSS or
Guardian session and applies to all applications running in the current session.
Precedence of the CLASSPATH Environment Variable
The UDR_JAVA_OPTIONS setting takes precedence over the CLASSPATH
environment variable. See Setting the Class Path by Using UDR_JAVA_OPTIONS on
page 2-22.
Setting CLASSPATH in the OSS Environment
To set the CLASSPATH environment variable in the OSS environment, enter this
command at an OSS prompt:
path1 and path2 are paths to JAR files or top-level directories where Java classes or
package directories exist. The paths must not include the package name.
For example, this command sets the class path for SPJs invoked in the current OSS
session:
export CLASSPATH="$CLASSPATH:/usr/otherapps/myJar.jar:
/usr/otherclasses"
For more information about the export command, see the Open System Services
Shell and Utilities Reference Manual.
Setting CLASSPATH in the Guardian Environment
To set the CLASSPATH environment variable in the Guardian environment, enter this
PARAM command at a Guardian prompt:
Note. NonStop ODBC/MX applications cannot use environment variables set in the OSS or
Guardian environment. See Setting the Class Path by Using UDR_JAVA_OPTIONS
on
page 2-22.
export CLASSPATH=["][$CLASSPATH:]path1[{:path2}...]["]
PARAM CLASSPATH path1[{:path2}...]