Re: I just can't use the org.postgresql.Driver class... Please help! - Mailing list pgsql-jdbc

From Andres Olarte
Subject Re: I just can't use the org.postgresql.Driver class... Please help!
Date
Msg-id 3fccaa690604101851t50f291cak23c2cee3cf3b59ba@mail.gmail.com
Whole thread Raw
In response to Re: I just can't use the org.postgresql.Driver class... Please help!  ("Guy Rouillier" <guyr@masergy.com>)
List pgsql-jdbc
You must catch an Exception that *might* be thrown, in this case it's
ClassNotFoundException.

Change:

public static void main(String[] args)
  {

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

  }

to

public static void main(String[] args)
  {
try {
  Class.forName("org.postgresql.Driver");
} catch (ClassNotFoundException e ){
}

  }


This way it'll compile.  This has nothing to do with JDBC, this is
basic Java stuff.

pgsql-jdbc by date:

Previous
From: "Michael Schmidt"
Date:
Subject: Re: Re; pg_dump from Java
Next
From: "Wei Wei"
Date:
Subject: Calendar vs. Timestamp