Re: [QUESTIONS] JDBC Driver from another machine

From: Peter T Mount <postgresdev(at)maidast(dot)demon(dot)co(dot)uk>
To: Mike Engelhart <mengelhart(at)pstrategies(dot)com>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: [QUESTIONS] JDBC Driver from another machine
Date: 1998-03-12 06:02:38
Message-ID: Pine.LNX.3.95.980312060044.2232C-100000@maidast
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-interfaces

[ cc'd to correct list]

On Wed, 11 Mar 1998, Mike Engelhart wrote:

> I'm wondering if i'm not understanding the use of JDBC, in particular the
> driver that is included with PostgreSQL v6.3. I've compiled the drivers
> fine on my LinuxPPC box. Knowing that, can't I just copy the .jar file or
> the individual class files and put them into the classpath of any
> development machine with a compatible VM and create Java applications that
> talk to the database? What i've tried unsuccessfully to do is write a

Yes, simply copy the postgresql.jar file. I've compiled here under Linux,
and used it under Windoze95, NT & Solaris with no problems

> simple app to connect to the database running on my LinuxPPC box from a
> Macintosh using Visual Cafe 2.0 (which has a JDK 1.1.3 compatbile VM). I
> made sure the .jar archive and/or the .class files were in the system
> classpath on my Mac, but I throw an execption (ClassNotFoundException) when
> I run the line of code:
> Class.forName("postgresql.Driver");

The jar file has to be defined in CLASSPATH, and not just in a directory
in the CLASSPATH.

--
Peter T Mount petermount(at)earthling(dot)net or pmount(at)maidast(dot)demon(dot)co(dot)uk
Main Homepage: http://www.demon.co.uk/finder
Work Homepage: http://www.maidstone.gov.uk Work EMail: peter(at)maidstone(dot)gov(dot)uk

Browse pgsql-interfaces by date

  From Date Subject
Next Message Bryan Hane 1998-03-12 14:29:28 Progress on JDBC Driver for PostgreSQL?
Previous Message Peter T Mount 1998-03-12 05:58:00 Re: [QUESTIONS] JDBC