This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
i have install the jdbc driver for sqlserver2000 under the "c:\jdbc" directory,and set the classpath to point to all of three jar files under it,the programs with "main" entry that access sqlserver works well,but the servlet that access database don't work,and it tell me "no suitable driver",then i move the jar files to "TOMCAT-HOME\lib",the servlet works well,i know that the files under the lib directory will be loaded when the tomcat start,but why the servlet can't identify the classpath with absolute path? otherwise,i learn that some jsp server such as jrun can config the servlet-chain,if the tomcat too?
but why the servlet can't identify the classpath with absolute path?
Thats because Tomcat sets its own CLASSPATH and doesn't use the env CLASSPATH or the user defined CLASSPATH. When Tomcat starts up, it echos' the CLASSPATH. You might verify that CLASSPATH to see if your drivers, in your absolute path, are in that CLASSPATH or not. And BTW, yes you can tweak the setup scripts of Tomcat, but I personally, don't do it unless it is absolutely essential. regds. - satya