Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> JDBC java drivers + Oracle 8.1.7 + Red Hat 7.0
Hi, I am a newbie and trying to run the JdbcCheckup.java file included in the samples and am getting the following error:
Exception in thread "main" java.lang.NoClassDefFoundError: oracle/jdbc/driver/OracleDriver
at JdbcCheckup.main(JdbcCheckup.java:13)
I added to the Classpath: CLASSPATH:$oracle_home/jdbc/lib/classes111.zip and compiled without any problems, but excuting the code (i.e. java JdbcCheckup) gives me the above error.
I have also tried compiling and executing with the class path flags:
javac -cp $oracle_home/jdbc/lib/classes111.zip JdbcCheckup.java (no error) java -classpath $oracle_home/jdbc/lib/classes111.zip (get above error)
Many thanks if you have any suggestions to put me on the right track.
-Simon
I am using:
Here's essentially my .bash_profile:
. ~/.bashrc
fi
export ORACLE_BASE=/db/u01/app/oracle
export ORACLE_HOME=/db/u01/oracle/product/8.1.7
export LD_LIBRARY_PATH=$ORACLE_HOME/jdbc/lib
export ORACLE_SID=ORA1
export ORACLE_TERM=ansi
export
PATH=$PATH:$ORACLE_HOME/bin:/usr/java/jdk1.3.1/bin:/usr/local/java/bin:/usr/
local/java/lib:/usr/java/jdk1.3.1/lib/tools.jar
export PATH=$PATH:usr/local/bin
export ORACLE_OWNER=oracle
TMPDIR=/var/tmp
export PATH TMPDIR
export CLASSPATH=/db/u01/oracle/product/8.1.7/jdbc/lib/classes111.zip
umask 022
ulimit -s 2048
#User specific environment and startup programs
PATH=$PATH:$HOME/bin
BASH_ENV=$HOME/.bashrc
export USERNAME BASH_ENV PATHReceived on Tue Jul 31 2001 - 10:42:29 CDT
____________________________________________________________________________
________________________