Solved

JDBC & JDeveloper

Posted on 2003-11-04
7
376 Views
Last Modified: 2012-06-21
After the failure of a test application, connecting to a remote Oracle database, I am trying to locate the portion of the Java source (generated by JDeveloper 9) that loads the driver and connects to the database. I can find nothing. Is there such code, or does JDev do a lot of hidden work?

I am asking because I also try to connect "manually", and the following line of code throws a NoClassDef... exception.

DriverManager.getConnection("jdbc:oracle:thin:@xxx.xxx.xxx.xxx1521:EKKE8", user, pass);

I am using 1.4.0 and I use ojdbc14_g.jar from Oracle.

0
Comment
Question by:piou
  • 3
  • 3
7 Comments
 
LVL 86

Expert Comment

by:CEHJ
ID: 9678659
>>and the following line of code throws a NoClassDef... exception.

Meaning which class?

If you put the driver jar in all lib\ext directories you should be OK if it's the driver class that's the problem.
0
 

Author Comment

by:piou
ID: 9678695
Apologies... the actual error is an error, not an exception:

Exception in thread "main" java.lang.NoClassDefFoundError: java/sql/Savepoint


0
 
LVL 86

Accepted Solution

by:
CEHJ earned 100 total points
ID: 9678755
You probably have a JDK < 1.4, which is when Savepoint appeared.
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 
LVL 92

Expert Comment

by:objects
ID: 9681711
Post the full stack trace.
0
 

Author Comment

by:piou
ID: 9685150
This is very strange. I had installed 1.4.0, but now I see that the default jre is 1.3.1! I suspect JDev messed it up. I will reinstall 1.4 and get back.

0
 

Author Comment

by:piou
ID: 9685162
indeed CEHJ... Thanks!!
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 9686236
:-)
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
Go is an acronym of golang, is a programming language developed Google in 2007. Go is a new language that is mostly in the C family, with significant input from Pascal/Modula/Oberon family. Hence Go arisen as low-level language with fast compilation…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now