Two Laptop Bag
The moose likes JDBC and Relational Databases and the fly likes error for connection jdbc Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "error for connection jdbc" Watch "error for connection jdbc" New topic

error for connection jdbc

weiliu lili
Ranch Hand

Joined: Apr 11, 2002
Posts: 46
i have already complied one example code succesfully, but when i run it ,there is error message
Registry key 'Software\JavaSoft\Java Runtime Environment\CurrentVersion'
has value '1.1', but '1.4' is required.
Error: could not find java.dll
Error: could not find Java 2 Runtime Environment.
i use Oracle8i Personal Edition Release - Production With the Java option
i use j2sdk1.4.0
how can i fix it up???
Part of my code is following:

by the way,ORCL should be the so-called sid,where can i find sid from database when i write other jdbc codes ,i think sid should be different everytime.
[ Edited by Dave to format code and remove smilies ]
[ April 11, 2002: Message edited by: David O'Meara ]
Col Bell

Joined: Mar 21, 2002
Posts: 12
Installing the Oracle Client _after_ you installed JDK1.4 can cause this problem. The oracle install also installs JDK1.1 and updates the Windows registry. There are two solutions. One is just to reinstall JDK1.4. The other (if you are brave) is to hack the registry. The need to change the value of the keys HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Development Kit and HKEY_LOCAL_MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment from 1.1 to the correct value for 1.4. This will be either 1.4 or 1.4.0 depending on which you have installed. If you expand the key you will see which one you have installed.
Remember if you do hack the registry to back it up first.
One more thing, the key above is for NT, I don't have access to a Win98 machine so you'll need to check your own registry.

Col<br /><a href="" target="_blank" rel="nofollow"></a>
I agree. Here's the link:
subject: error for connection jdbc
It's not a secret anymore!