tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "amit" <a...@realityinfo.com>
Subject Re: Pls Help
Date Wed, 21 Jun 2000 05:20:03 GMT


Hi,
        Try to include following Code:
<%@ page import="java.sql.*" %>

        If still problem persists send the error details.


Bye.
-Amit
amit@realityinfo.com
----------------------------------------------------------------------------
------------------------


Hi,

Can anyone pls tell me how to connect a jsp to a db? i have a jsp page, a
java bean and a sql server 7.0 db on my pc. i have config the odbc for the
db via control panel.

now how do i activate the jdbc bridge (i presume it comes with java 2 sdk
1.3)? do i need to install anything or move certain files from folder to
folder?

and where do i place these 2 lines of code? in the jsp or in the java
bean??
and can i just place them on top in the codes just like any jsp codes?
(useBean etc)

these are the 2 lines i am talking about:

Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");

Connection con = DriverManager.getConnection(url, "myLogin", "myPassword");

and do i have to hard code/ specify the url, login and password above?
Thanks

Darren
________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


--------------------------------------------------------------------------
To unsubscribe, email: tomcat-user-unsubscribe@jakarta.apache.org
For additional commmands, email: tomcat-user-help@jakarta.apache.org




Mime
View raw message