JSP to PostgreSql

From: "Shavonne Marietta Wijesinghe" <shavonne(dot)marietta(at)studioform(dot)it>
To: <pgsql-jdbc(at)postgresql(dot)org>
Subject: JSP to PostgreSql
Date: 2008-04-01 09:19:36
Message-ID: 007001c893d9$83632bc0$0602a8c0@DREAM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Hello. I'm trying to connect my jsp page to read a database on a windows 2003 server.

<%@ page language="java" import="java.sql.*" %>
<body>
<%
Class.forName("org.postgresql.Driver");
Connection myConn=DriverManager.getConnection("jdbc:postgresql://XXX.XXX.X.X/database/FormAjax?user=postgres&password=form");
%>
</body>

But when i run this i get an "Exception report" error

org.apache.jasper.JasperException: Exception in JSP: /jsp/pgtest.jsp:10
7:
8: Class.forName("org.postgresql.Driver");
9:
10: Connection myConn=DriverManager.getConnection("jdbc:postgresql://192.168.2.3:8080/database/FormAjax?user=postgres&password=form");
11:
12: %>
13: </body>

Any idea anyone?
Thank you.
Shavonne

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Albe Laurenz 2008-04-01 10:08:43 Re: JSP to PostgreSql
Previous Message Albe Laurenz 2008-04-01 08:03:34 Re: CallableStatement and getUpdateCount