-
Junior Member
Jdbc
is it possible to use type1 driver in web application?
if so give me an example....
-
Junior Member
Re: Jdbc
Hello ,
Geek members ,hai!.
Please send me the interview Q&A
forsolving java programs .
-
Junior Member
Re: Jdbc
Yes you can use Type1 Driver in Web Applications
the example is following:-
Make a database in MS Access or in MS Excel and use it as a database
suppose u have made a table say "Table1" in MS Access database say "db1" and DSN is "MyAccess" then this programme will help you
<%@ page import="java.sql.*" %>
<html>
<body>
<%
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
Connection conn=DriverManager.getConnection("jdbcdbc:MyAccess");
Statement stmt=conn.createStatement();
ResultSet result=stmt.executeQuery("select * from Table1");
while(result.next())
{
out.println(result.getType(Column-name)+..............)
}
%>
</body>
</html>
-
Re: Jdbc
Hi Nikhil,
u r absolutely right.........
Type 1 driver can be used in web application.
The example is good.......
Regards,
riju
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules