[TriLUG] dev question

Owen Berry trilugbucket at berrybunch.net
Thu Feb 19 08:39:39 EST 2004


Not sure which one you will need to use, but putting the directory in
your classpath won't work, as far as I remember. In terms of your
classpath, a jar file is equivalent to a directory - the loader searches
either a directory or a jar file for class files. If you need to include
all those jars you will need to list them individually.

Owen

On Thu, 2004-02-19 at 08:20, William Sutton wrote:
> Excellent!  I have a series of jdbc jar files in /usr/share/pgsql:
> 
> -rwxr-xr-x    1 root     root       131792 Nov  4 15:45 pg73jdbc1.jar*
> -rwxr-xr-x    1 root     root       163980 Nov  4 15:45 pg73jdbc2.jar*
> -rwxr-xr-x    1 root     root       184176 Nov  4 15:45 pg73jdbc3.jar*
> 
> Is there a specific one I should use or can I get away with putting the 
> entire /usr/share/pgsql directory in my CLASSPATH env?
> 
> William
> 
> On Thu, 19 Feb 2004, Steve Kuekes wrote:
> 
> > William Sutton wrote:
> > 
> > > Just for fun I'm working on an independent project to teach myself Java, 
> > > including JDBC.  When I installed the system (Red Hat 9), I included 
> > > PostgreSQL and the appropriate JDBC driver:
> > > 
> > > << snipped stuff >>
> >  >
> > > Any suggestions from either the Java gurus or the Red Hat folks as to why 
> > > this is happening?
> > > 
> > > William Sutton
> > > 
> > 
> > You need to make sure that the postgres jar file is in your classpath so 
> > that it can be found.  For example:
> > 
> > CLASSPATH=.:/var/tomcat4/common/lib/log4j.jar:/usr/share/pgsql/jdbc7.1-1.2.jar
> > 
> > You need to find your postgres jdbc jar file for your release.  My 
> > server is running an old one, so your location may vary.
> > 
> > The compile time stuff is included with the java.sql.* stuff (that's why 
> > your compile is working) and is bound with the jdbc driver at run time 
> > when you load the driver (which isn't working).
> > 
> > Hopefully this is the problem.
> > 




More information about the TriLUG mailing list