Incontro questo tipo di errore in explorer richiamando
test.jsp: (altri file già funzionano con il web server)
errore:
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
test.jsp è:
<%@ page session="false" %>
<%@ page import="java.sql.*, java.util.* %>
<html>
<head>
<title>Titolo</title>
</head>
<body>
<%
string Driver = "sun.jdbc.odbc.JdbcOdbcDriver";
Class.forName(Driver);
// database nella stessa cartella di pagina test.jsp
string URL = "dba.mdb";
string strcon = "jdbcdbc
river={Microsoft Access Driver (*.mdb)};DBQ="+URL;
connection con = null;
con=DriverManager.getConnection(strcon, "", "");
string sql = "SELECT ragione_sociale, indirizzo FROM Clienti";
Statement stmt =con.createStatement();
ResultSet rs = stmt.executeQuery(sql);
%>
Titolo della tabella
<table width="50%" border="10">
<tr>
<th>Ragione_sociale</th>
<th>Indirizzo</th>
</tr>
<%
while (rs.next()) {
String ragione_sociale = rs.getString(1);
String indirizzo = rs.getString(2);
%>
<tr>
<td><%= ragione_sociale%></td>
<td><%= indirizzo%></td>
</tr>
<%
}
rs.close;
rs=null;
stmt.close();
stmt=null;
con.close();
%>
</table>
</body>
</html>
Cosa sbaglio?