Re: JDBC Driver Help... - Mailing list pgsql-interfaces

From Joachim Achtzehnter
Subject Re: JDBC Driver Help...
Date
Msg-id Pine.LNX.4.21.0009052238070.505-100000@wizard.kraut.bc.ca
Whole thread Raw
In response to JDBC Driver Help...  (Eric Buschelmann <ehb@one.net>)
List pgsql-interfaces
Yesterday, in a message to pgsql-interfaces, Eric Buschelmann wrote:
> 
> public class Test extends Applet

You should try an application first before complicating things with applet
issues. Once you get JDBC working with an application you can go on to an
applet.

>       Class.forName("org.postgresql.Driver").newInstance();

Creating an instance is not necessary, just load the class:
 Class.forName("org.postgresql.Driver");

>       con=DriverManager.getConnection("jdbc:postgresql:ehb","ehb","rhimgeti");

This looks ok.

>      catch (SQLException excpt0)
>          {
>       textArea2.setText("SQL EXCEPTION ON QUERY!!!");
>          }

To obtain some more info about the failure print a stack trace:
 excpt0.printStackTrace();

Are you running the postmaster with the -i flag? Did you configure
Postgresql to permit TCP connections from the host where your
application/applet runs?

Joachim

-- 
work:     joachima@realtimeint.com (http://www.realtimeint.com)
private:  joachim@kraut.bc.ca      (http://www.kraut.bc.ca)




pgsql-interfaces by date:

Previous
From: Eric Buschelmann
Date:
Subject: JDBC Driver Help...
Next
From: Peter Mount
Date:
Subject: RE: JDBC and Unicode problem