loadjava:
This is OS based utility tool by Database. This command will be available in the OS. This can be run by Command Prompt (cmd) in Windows or Shell in UNIX/LINUX.
- Windows:
- goto the jar existing path in Command Prompt (cmd)
- loadjava -resolve -user scott/tiger@demo SQLJ.jar
Issue the above command , If the error loadjava command not found is coming up then set environment variables like PATH, JAVA_HOME then issue loadjava command.
- UNIX/Linux
- Set parameters
- To execute the loadjava in server environment directly, it is better to set the following parameters.
- $ export ORACLE_HOME=/scratch/oracle/app/oracle/product/11.2.0/dbhome_1
- $ export PATH=$ORACLE_HOME/bin:$PATH:.
- $ export ORACLE_SID=DEMO
- goto the jar existing path in Shell
- loadjava -resolve -user scott/tiger@demo SQLJ.jar
- Set parameters
Errors:
ORA-29534: referenced object cannot be resolved
Cause: In case of loading multiple Jars
It might be because the internal sources of a Jar referring to another source in another jar.
So load all the jars at once to avoid the above error as follows
loadjava -resolve -user scott/tiger@demo *.jar
It will load all the jars existing in the folder/directory/path mentioned
Reference Links:
Refer the following links for detailed information of the tool
http://docs.oracle.com/cd/B28359_01/java.111/b31225/chtwo.htm
http://docs.oracle.com/cd/B28359_01/java.111/b31225/cheleven.htm#CACFHDJE