• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 374
  • Last Modified:

JDBC Connection ERROR

Hi friends...

  My Database is SQLBase.

  I have downloaded the JDBC Type 4 driver from centura site.
I run it and installed in c:\com\centurasoft\java\sqlbase
directory.

My class path is
Set classpath = .;c:\jdk1.2.2\lib\dt.rar;c:\com\centurasoft\java\sqlbase

In my program as follows..

Class.forName("centura.java.sqlbase.SqlbaseDriver");

but its showing an exception saying that..No suitable driver found.
when i change the class path, it shows another exception  that "wrong name(com\centurasoft\java\sqlbase\SqlbaseDriver)"

I'm not able to load the Sqlbase driver..
I'm using JDK1.2.2 nd win98,..database in NT
please help me

thanks
Jim
0
jimaricat072100
Asked:
jimaricat072100
1 Solution
 
anhphuongnnCommented:
Hi Jim,

You find driver file *.zip or *.jar
And then you add filename.zip in end of path.

Set classpath = .;c:\jdk1.2.2\lib\dt.rar;c:\com\centurasoft\java\sqlbase\filename.zip


Best Regards
Phuongnguyen
0
 
ruifilipevaleCommented:
Hello!
You can make a jar from the driver classes, only and only if you have them extracted to the dir c:\com\centura\........

In a dos shell:

cd c:\com
c:\jdk1.2.2\bin\jar cvf YourDriver.jar centura

Then copy the resulting YourDriver.jar to c:\jdk1.2.2\jre\lib\ext\

This sould solve your problems.

Run your program using the full path to java. (probably c:\jdk1.2.2\bin\java)

Hope it helps!


          RFV
0
 
jimsimsCommented:
your classpath and the driver path given don't match:

Class.forName("centura.java.sqlbase.SqlbaseDriver");

Set classpath = .;c:\jdk1.2.2\lib\dt.jar;c:\com\centurasoft\java\sqlbase

likely you just need to change your classpath to:

Set classpath = .;c:\jdk1.2.2\lib\dt.jar;c:\

and set the driver to:

Class.forName("com.centurasoft.java.sqlbase.SqlbaseDriver")

e.g. - either both should say centurasoft or centura
and almost certainly both should start with com.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now