I'm going to jump right in.
I have a java file called DBCon that connects to a database, and then runs SQL. When I run the java file in netbeans, it properly queries the information from the text file that I am accessing.
I am in Oracle through putty and am trying to run the java file.
export CLASSPATH="./:/opt/lablibs/ojdbc6.jar"
javac DBCon.java
java DBCon
- the export statement gathers the ojdbc6.jar file from the server at my school. This code was given to us by our teacher.
- then you compile the java application, which works just fine.
- when I try and run, I get an error that says:
Exception in thread "main" java.lang.NoClassDefFoundError: DBCon (wrong name:
assignment3/DBCon)
What am I missing? Everything works until this point.