Win a copy of The Java Performance Companion this week in the Performance forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Connection OK in JDK1.3, but fails in JDK1.4

 
Patrick Muls
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm using a JDBC connection to access an Oracle db. Using JDK 1.3 it functions OK with the following run-command:
set JDK=C:\jdk1.3.1\jre
set PROJ=C:\Distro
set ORACLE=%PROJ%\classes12.zip
set path=.;%JDK%\bin;
set classpath=.;%PROJ%;%ORACLE%;%JDK%\jre\lib\rt.jar;
set classpath
java -version
java -Duser.language=nl -Duser.region=BE -jar NAL.jar
pause
However using the same command to use JDK1.4, I get an SQLSTATE='080004' saying it is not possible to connect to this driver. The commandfile, program-jar, and DB however are the same:
set JDK=C:\Program Files\Java\j2re1.4.1_01
set PROJ=C:\Distro
set ORACLE=%PROJ%\classes12.zip
set path=.;%JDK%\bin;
set classpath=.;%PROJ%;%ORACLE%;%JDK%\jre\lib\rt.jar;
set classpath
java -version
java -Duser.language=nl -Duser.region=BE -jar NAL.jar
pause
Has anybdy any suggestions to explain, and resolve, this strange behavior?
Patrick Muls
Datassur, Belgium
 
Patrick Muls
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
We got around to solving this problem. It turns out that the environment variable PROJ doesn't seem to play any role in allocating the driver zipfile to the application. Putting the classes12.zip file in the EXT-directory of the JDK however did solve the problem.
 
Patrick Muls
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry, I meant variable ORACLE, not PROJ
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic