This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JDBC and the fly likes Runtime Eror Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Runtime Eror" Watch "Runtime Eror" New topic
Author

Runtime Eror

Geetha Sarath
Greenhorn

Joined: Aug 08, 2005
Posts: 10
hi,
Iam new to java,trying to connect with sqlserver7.0
my program is compling fine,while execution,Iam
getting the following error

Exception in thread "main" java.lang.NoClassDefFoundError: test

how to solve this problems,help me guys.
Thanks.
Dave Salter
Ranch Hand

Joined: Jul 20, 2005
Posts: 292

Sounds like you probably don't have the SQL Server JDBC driver on your class path.

If this is the case, check out the jTDS drivers.
David Ulicny
Ranch Hand

Joined: Aug 04, 2004
Posts: 724
You are missing the class test on your classpath, start the program with
-cp switch

java -cpFullPathToClass test


SCJP<br />SCWCD <br />ICSD(286)<br />MCP 70-216
Dave Salter
Ranch Hand

Joined: Jul 20, 2005
Posts: 292

David,

I think yu're right. I missed that the original post said the class "test" could not be found.

Sorry for any confusion.

Dave.
David Ulicny
Ranch Hand

Joined: Aug 04, 2004
Posts: 724
Dave, I think that your answer will be for Geetha Sarath also very usefull. Classpath problems are very common here on Javaranch.
Geetha Sarath
Greenhorn

Joined: Aug 08, 2005
Posts: 10
Thanks for ur suggestion,i wl try and get u back guys.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60785
    
  65

Geetha, JavaRanch is a community of people from all over the world, many of who are not native English speakers. While using abbreviations like "u" instead of spelling out "you" is convenient when text messaging your friends on a cell phone or in a chat room, it presents an extra challenge to those that are already struggling with English. Additionally, such shortcuts may confound automated translation tools that patrons of the Ranch may be making use of.

I would like to ask for your help in making the content of JavaRanch a little easier to read for everybody that visits here by not using such abbreviations.

Please read this for more information.

thanks,
bear
Forum Bartender


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Runtime Eror
 
Similar Threads
help help help
indexOf
How old are you ?
Different Beers that I have tasted !
Drivel