<%
// Load the driver. Ensure JSQLConnect.jar is deployed into the servet engine's classpath.
// You will need to restart the servlet engine after deploying the driver JAR to the classpath.
Class.forName("com.jnetdirect.jsql.JSQLDriver");
// Make the DBMS connection
Connection connection = DriverManager.getConnection(connectionURL);
// Make the statement
Statement statement = connection.createStatement();
// Generate query
String Query = "SELECT * FROM AAL_DESTINO";
// Get the result and display it
ResultSet queryResult = statement.executeQuery(Query);
while(queryResult.next()) {
out.println("
"+queryResult.getString(1)+"
"+queryResult.getString(2)+"
");
}
// Close the connection
queryResult.close();
statement.close();
connection.close();
%>