my dog learned polymorphism
The moose likes Beginning Java and the fly likes jdbc questions Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "jdbc questions" Watch "jdbc questions" New topic

jdbc questions

Chris Davies
Ranch Hand

Joined: Feb 26, 2003
Posts: 110

i'm trying to compile the following code using a 3rd party driver. by using the following

javac -classpath "C:\beans"

and getting the following error 'class' or 'interface' expected
public Class webtopjdbc {
^ package basiswebtop does not exist
import basiswebtop.*;
^ package basisjdbc does not exist
import basisjdbc.*;

do i have to use the main method ?

do i have to instantiate the class ?

do i have to use the import statements ?

both jar files are in the directory so why isn't it being read ?



One day all greenhorns will run free ...
Paul Sturrock

Joined: Apr 14, 2004
Posts: 10336

You've written the class keyword with an uppercase 'C'.

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
Chris Davies
Ranch Hand

Joined: Feb 26, 2003
Posts: 110
thanks. it worled when i changed it and the compile line to javac -classpath "C:\beans\ "

its funny though, when i run the command and it returns to the prompt (giving no message as always - inferring its compiled), and yet its not there in the directory ?? vai command line or windows explorer interface ?
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63355

This is a basic java compilation issue and not related to JDBC, so I'm moving this off to the Java in General(beginner) forum for further discussion.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: jdbc questions
It's not a secret anymore!