I've set up my ODBC connection on my linux desktop and I can now connect to the database using isql. The command I use is isql GSPDEV2 username password.
However, even thought I can connect using isql I am still getting the error below.
$ java -classpath “\usr\lib\oracle\xe\app\oracle\product\10.2.0\client\jdbc\lib\ojdbc14.jar:saxon.jar:.:jeval.jar:lucene-core-2.2.0.jar:jxl.jar” Profilerfsdfas
Exception in thread "main" java.lang.NoClassDefFoundError: Profilerfsdfas
Caused by: java.lang.ClassNotFoundException: Profilerfsdfas
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
Do you have any idea what the issue might be? By the way, you asked if I can tnsping to the server but tnsping doesn't seem to be on this machine because I downloaded only the oracle client and not the full installation.
Thanks for your help,
- Frank
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
1.) DSN is the system DSN that you create. You can look into installation guide on how to create DSN.
2.) Database_Driver="sun.jdbc.odbc.JdbcOdbcDriver" you can change with the driver to the you are using it. It is the default one that is shipped with JDK. It might work for you.
3.) There are some extra characters after Profiler remove that "Profilerfsdfas"
4. No need to give \usr\lib\oracle\xe\app\oracle\product\10.2.0\client\jdbc\lib\ojdbc14.jar in classpath as you are not user Native driver.
Let me know if you face any further problem.
Regards,
Vivek
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi Vivek,
I've set up my ODBC connection on my linux desktop and I can now connect to the database using isql. The command I use is isql GSPDEV2 username password.
My configFile.txt is below.
Database_Type="ORACLE_NATIVE"
Database_Driver="oracle.jdbc.OracleDriver"
Database_Protocol="jdbc:oracle:oci8"
Database_DSN="GSPDEV2"
Database_User="username"
Database_Passwd="password"
Database_Catalog=""
Database_SchemaPattern="GSQA"
Database_TablePattern=""
Database_TableType="TABLE"
Database_ColumnPattern=""
However, even thought I can connect using isql I am still getting the error below.
$ java -classpath “\usr\lib\oracle\xe\app\oracle\product\10.2.0\client\jdbc\lib\ojdbc14.jar:saxon.jar:.:jeval.jar:lucene-core-2.2.0.jar:jxl.jar” Profilerfsdfas
Exception in thread "main" java.lang.NoClassDefFoundError: Profilerfsdfas
Caused by: java.lang.ClassNotFoundException: Profilerfsdfas
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:276)
at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
Do you have any idea what the issue might be? By the way, you asked if I can tnsping to the server but tnsping doesn't seem to be on this machine because I downloaded only the oracle client and not the full installation.
Thanks for your help,
- Frank
Hi Frank,
If you are using ODBC connection you should use the following Block
Database_Type="ORACLE_ODBC"
Database_Driver="sun.jdbc.odbc.JdbcOdbcDriver"
Database_Protocol="jdbc:odbc"
Database_DSN="???"
Database_User="???"
Database_Passwd="???"
Database_Catalog=""
Database_SchemaPattern="???"
Database_TablePattern=""
Database_TableType="TABLE"
Database_ColumnPattern=""
1.) DSN is the system DSN that you create. You can look into installation guide on how to create DSN.
2.) Database_Driver="sun.jdbc.odbc.JdbcOdbcDriver" you can change with the driver to the you are using it. It is the default one that is shipped with JDK. It might work for you.
3.) There are some extra characters after Profiler remove that "Profilerfsdfas"
4. No need to give \usr\lib\oracle\xe\app\oracle\product\10.2.0\client\jdbc\lib\ojdbc14.jar in classpath as you are not user Native driver.
Let me know if you face any further problem.
Regards,
Vivek
Hi Vivek:
Thanks for your suggestion.
I can now use ODBC and the profiler to connect to the database.
I appreciate all your help.
- Frank