jsp postgresql problems

From: "Ryan Skoblenick" <webmaster(at)skoblenick(dot)com>
To: <pgsql-jdbc(at)postgresql(dot)org>
Subject: jsp postgresql problems
Date: 2002-03-03 23:51:47
Message-ID: 000801c1c30e$624daa20$bb372a18@cr704668a
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

This is my code:
<%@ page import ="java.sql.*" %>

<%

Driver drv = (Driver)Class.forName("org.postgresql.Driver").newInstance(); Connection conn = java.sql.DriverManager.getConnection("jdbc:postgresql://localhost:5432/db_name", "username", "password");

%>

now the stack error i am running into is:

Connection refused. Check that the hostname and port is correct, and that the postmaster is running with the -i flag, which enables TCP/IP networking.

i know its not the server or the way it is setup cause i can connect to the DB in ASP? so what is wrong with the JSP? i do have the drivers installed for postgresql cause the first error before this i was getting was that it couldn't find the drivers (silly me forgot to reset the server).

anyone help ?

Thanks

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Chantal Ackermann 2002-03-04 08:43:54 Re: Postgress 7.2 and j2sdk 1.4.0
Previous Message Barry Lind 2002-03-02 19:57:40 Re: JBuilder 4 QDS problem