You should provide a bit more information. As you are talking about dll's, I assume that you are using one of mr. gates kids (which one).
Do you run tomcat as a service ? Which user is running the vm for your tomcat ? Is it the same user that you use to run test.java? Maybe you should print out the environment in your test cases to see if there is a difference. > -----Urspr�ngliche Nachricht----- > Von: Roland Dong [mailto:[EMAIL PROTECTED]] > Gesendet: Montag, 21. Januar 2002 17:59 > An: Tomcat Users List; Alex Chaffee > Betreff: Still have no answer for this! > > > I have installed tomacat to set up Oracle JDBC-ODBC driver, > data source... but ran into some problmes: > > The database connection with Oracle only works with .java > files but does not work with jsp files. > > For example: test.java would work but test.jsp would not. > > This is the error message I got when running with test.jsp: > > "OCI.DLL: One of the library files needed to run this > appliction cannot be found". Can anyone tell me what might > be the problem? I checked the dll dependency for OCI.DLL, > all dll files are there. > > Please help > > Roland > > This is my test.jsp program: > > > > > <%@ page info="database handler"%> > <%@ page import="java.io.*"%> > <%@ page import="java.util.*"%> > <%@ page import="java.sql.*"%> > > <%@ page import="javax.servlet.*"%> > <%@ page import="javax.servlet.http.*"%> > <% > > try > { > Connection con=null; > Statement stmt=null; > ResultSet rs=null; > String createString=null; > Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); > > String url="jdbc:odbc:test"; > con = DriverManager.getConnection(url,"scott", "tiger"); > createString="select FIRST_NAME,EMPLOYEE_ID,SALARY from > emp"; > stmt=con.createStatement(); ; > rs = stmt.executeQuery(createString); > > while (rs.next()) > { > String col1 = rs.getString(1); > String col2 = rs.getString(2); > > out.println("<tr><td>"+col1+"</td><td>"+col2+"</td></tr>"); > } > out.println("</table>"); > } > catch (Exception e) {} > %> > > -- > To unsubscribe: <mailto:[EMAIL PROTECTED]> > For additional commands: <mailto:[EMAIL PROTECTED]> > Troubles with the list: <mailto:[EMAIL PROTECTED]> > > > -- To unsubscribe: <mailto:[EMAIL PROTECTED]> For additional commands: <mailto:[EMAIL PROTECTED]> Troubles with the list: <mailto:[EMAIL PROTECTED]>
