RE: problem with driver

From: Peter Mount <petermount(at)maidstone(dot)gov(dot)uk>
To: "'Davis'" <davis(at)elixirtech(dot)com>, pgsql-interfaces(at)postgresql(dot)org
Subject: RE: problem with driver
Date: 2000-10-17 09:53:23
Message-ID: 1B3D5E532D18D311861A00600865478CF1B435@exchange1.nt.maidstone.gov.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

Ok, no such driver means that either you are not loading the driver, or
theres a syntax error in the jdbc url you are providing.

1: Load the driver. For pre 7.0 backends, the driver class is
postgresql.Driver whereas for 7.0 and later its org.postgresql.Driver

You have several methods of loading it. For java applications you can use
the
-Djdbc.drivers=postgresql.Driver
parameter to java, or the line:
Class.forName("postgresql.Driver");

2: The JDBC url MUST begin with jdbc:postgresql:

ie: jdbc:postgresql:test for local db's
jdbc:postgresql://host/database for remote databases

Peter

--
Peter Mount
Enterprise Support Officer, Maidstone Borough Council
Email: petermount(at)maidstone(dot)gov(dot)uk
WWW: http://www.maidstone.gov.uk
All views expressed within this email are not the views of Maidstone Borough
Council

-----Original Message-----
From: Davis [mailto:davis(at)elixirtech(dot)com]
Sent: Monday, October 16, 2000 8:47 AM
To: pgsql-interfaces(at)postgresql(dot)org
Subject: [INTERFACES] problem with driver

Hi all,

I am very new to postgresql. I am working in linux machine and I have
builtin postgres server version 6.5.2. I am able to play around with sql

through command line. But When I tried to connect through my java
application it thowing SQLexception saying no suitable driver. I tested
with both "org.postgresql.Driver" and "postgresql.Driver" including
"postgresql.jar "driver file and "jdbc6.5-1.2.jar" driver files.
somebody please help me saying which Driver we need to use to connect to
the above server. Or please let me know how to solve this particular
problem. Any commands in this issue is welcome. Your interest in this
regard is hihgly appreciated.

Thanks in advance

Davis

Browse pgsql-interfaces by date

  From Date Subject
Next Message Peter Mount 2000-10-17 09:55:43 RE: Save java objects using JDBC
Previous Message Peter Mount 2000-10-17 08:36:20 RE: datetime fix