Re: Trouble With JDBC

From: Corey Mosher <corey(at)pgsql(dot)com>
To: Bob Kline <bkline(at)rksystems(dot)com>
Cc: Corey Mosher <corey(at)pgsql(dot)com>, pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Trouble With JDBC
Date: 2001-02-16 19:32:13
Message-ID: Pine.BSF.4.21.0102161530240.27763-100000@rage.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

So there has got to be something wrong with the way I'm setting my classpath
in that when I type java sample it is trying to use sample.java instead
of sample.class.

I'll play around with the classpath and see what I come up with.

Thanks Bob, I appreciate it.

Corey

On Fri, 16 Feb 2001, Bob Kline wrote:

> I'm not saying I doubt what you're telling me about how you're trying to
> run the program, but you might want to try again. Watch this:
>
> $ javac sample.java
> $ java sample
> Enter a state code: VA
> Virginia
> $ java sample.java
> Exception in thread "main" java.lang.NoClassDefFoundError: sample/java
>
> Look familiar?
>
> Good luck,
> Bob
>
> On Fri, 16 Feb 2001, Corey Mosher wrote:
>
> > The source code is from the book:
> > PostgreSQL: Introduction And Concepts
> >
> > Located at: http://www.postgresql.org/docs/aw_pgsql_book/node192.html
> >
> > I wanted to use some code that I knew worked to overcome problems
> > like I am having.
> >
> > Corey
> >
> >
> > On Fri, 16 Feb 2001, Bob Kline wrote:
> >
> > > On Fri, 16 Feb 2001, Corey Mosher wrote:
> > >
> > > > No, to run the program I am using:
> > > > java sample
> > > >
> > > > To compile it I am using:
> > > > javac sample.java
> > > >
> > > > I have had other simple programs running (the usual hello world
> > > > apps) and they seem to work fine. Just this one for some reason
> > > > gets the error.
> > >
> > > Let's take a look at the source, then, to see if we can spot the
> > > problem.
> > >
> > >
> >
> > Corey Mosher
> >
> > -----------------------------
> > Hub.Org Networking Services
> > 251 Main St.
> > Wolfville, NS
> > Canada
> > B0P 1X0
> > Email: corey(at)hub(dot)org
> > Phone: (902) 542-3657
> > -----------------------------
> > PostgreSQL, Inc.
> > 251 Main St.
> > Wolfville, NS
> > Canada
> > B0P 1X0
> > Email: corey(at)pgsql(dot)com
> > Phone: (902) 542-0713
> > -----------------------------
> > Fax: (902) 542-5386
> >
>
>

Corey Mosher

-----------------------------
Hub.Org Networking Services
251 Main St.
Wolfville, NS
Canada
B0P 1X0
Email: corey(at)hub(dot)org
Phone: (902) 542-3657
-----------------------------
PostgreSQL, Inc.
251 Main St.
Wolfville, NS
Canada
B0P 1X0
Email: corey(at)pgsql(dot)com
Phone: (902) 542-0713
-----------------------------
Fax: (902) 542-5386

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Mirko Zeibig 2001-02-16 20:00:21 Re: newbie: retep wants to have username?
Previous Message Bob Kline 2001-02-16 19:16:40 Re: Trouble With JDBC