java error (No suitable driver found)

Solution 1:

  1. You'll need to load the driver somewhere. Class.forName("org.postgresql.Driver");
  2. You'll need the postgresql driver .jar file in the classpath of your program.

Solution 2:

You need to put the postgreSQL JDBC driver on your classpath.

See the official documentation for instructions.

Solution 3:

Did you add Postgresql driver to your classpath?

http://jdbc.postgresql.org/