That's where the error comes from. I'm trying to use JSP to connect to my DB. The connection line doesn't appear to give any errors, but it is tough to tell since this line doesn't work... without this line I get a connection problem anyways because this line isn't there.
I have used practically identicle code in Java Apps before and it worked without a problem. I am new to JSP in general, but regular pages do work. This is the exception I "out.print" to the screen upon connection try failure.
I am running the most recent version of Tomcat as my JSP server on a Windows 2000 machine.
I also have classes12.zip in the Tomcat/common/lib directory as well as added it to my CLASSPATH in the Environmental Variables even though, from all the searches I have done, the most recent version of Tomcat does not even use the system CLASSPATH anymore. But figured it couldn't hurt.
Any help would be greatly appreciated, I am doing this on the side but I must be missing something.
I am attempting to connect to an Oracle 9i database.
Same error... doesn't seem to have helped renaming it to .jar instead of .zip.
Btw, I also put the .jar into my CLASSPATH anyways, just in case by some fluke it decided to use it.
[ December 09, 2002: Message edited by: Jeff Grant ]
Originally posted by Michael Zalewski:
Put classes12.zip into your WEB-INF/lib directory. (Or into your .war file at that spot).
Alternatively, you can add it to Tomcat's classpath by sticking it into tomcat.bat (tomcat.sh, Catalina.bat... whatever it is depends on your version of tomcat and platform).
Tried it... no luck, stuck it in Catalina.bat. Next idea?
The only reply I got was all that helped me. Come on guys, where were you?!
Anyways, turned out I had a bunch of things wrong with my Tomcat setup. I did have to unzip then jar the Classes12.zip for use with Tomcat.
I also tried the %CATALINA_HOME%\bin\setclasspath.bat from the command prompt and saw it had many errors in it.
Firstly, I had my JAVA_HOME pointing to a Java directory, but it did not contain all the exe's which setclasspath.bat was looking for.
I also did not have the variable BASEDIR defined in my Environmental Variables... causing setclasspath.bat to end early.
From here, it still did not work, but at least my startup of Tomcat was no longer giving errors.
I tried changing the classpath in setclasspath.bat to include the newly created Classes12.jar. But that still did not help.
Come to find out, you don't need to set any classpath differently, just place the file you want included inside the %CATALINA_HOME%\shared\lib folder.
Worked like a charm from there!
Now I haven't had a chance to actually run a query. But I think the tough part is over with.. I hope this thread helps someone else by the listing of my trials and errors.
[ December 10, 2002: Message edited by: Jeff Grant ]