Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search archives
  Advanced Search

Re: JDBC connection issue


  • From: Dave Cramer <pg(at)fastcrypt(dot)com>
  • To: Young Nam <Ynam(at)sharedmarketing(dot)com>
  • Cc: Kris Jurka <books(at)ejurka(dot)com>, "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org>
  • Subject: Re: JDBC connection issue
  • Date: Tue, 13 Jul 2004 15:15:03 -0400
  • Message-id: <1089746103.1506.377.camel@localhost.localdomain> <text/plain>

When you run a java program using -jar jarfile, java will ignore the
CLASSPATH. This is why it can't find postgres.

Dave
On Tue, 2004-07-13 at 14:20, Young Nam wrote:
> CLASSPATH is set to
> /usr/local/pgsql/share/java/postgresql.jar:/home/youngnam/Development/java_apps/xlang/bin/Xlang.jar
> 
> I am using ant to build the source files and create jar file.
> In build.xml file, target that runs the program is,
> 
> <target name="run" depends="build">
>   <java jar="${target}" fork="true"/> where ${target} is bin/Xlang.jar
> </target>
> 
> Thanks again,
> 
> YJ
> 
> -----Original Message-----
> From: Kris Jurka [mailto:books(at)ejurka(dot)com]
> Sent: Tuesday, July 13, 2004 1:07 PM
> To: Young Nam
> Cc: pgsql-jdbc(at)postgresql(dot)org
> Subject: Re: [JDBC] JDBC connection issue
> 
> 
> 
> 
> On Tue, 13 Jul 2004, Young Nam wrote:
> 
> > Thanks for speedy replies, Kris.
> > 
> > I've included both jar files in the CLASSPATH.  Same error.
> > 
> 
> What exactly is the CLASSPATH and what exact command are you running java 
> with?
> 
> Kris Jurka
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 7: don't forget to increase your free space map settings
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
> 
> 
> 
> !DSPAM:40f428f2313221402172797!
> 
> 
-- 
Dave Cramer
519 939 0336
ICQ # 14675561




Home | Main Index | Thread Index

Privacy Policy | About PostgreSQL
Copyright © 1996 – 2012 PostgreSQL Global Development Group