aspose file tools*
The moose likes JDBC and the fly likes NoClass definitopn found error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "NoClass definitopn found error" Watch "NoClass definitopn found error" New topic
Author

NoClass definitopn found error

Maan Suraj
Ranch Hand

Joined: Dec 20, 2007
Posts: 299
I am new to HSQLDB and jdbc....i have installed tomcat 6.0 as my web server. I have installed hsqldb_1_8_0_10 database. Database installation is succesfull as i can open the editor the database and tried inserting the tables....which were succesfull.....
But now i want to connect to my db from the java file. For that i used "FindFile.java" which is present in the guide provided in the download.

path is
C:\hsqldb\src\org\hsqldb\sample\FindFile.java.




I have created an application in webapps folder of tomcat


folder structure
webapps/ch1/WEB-INF--->web.xml
--->org/hsqldb/sample/FindFile.class


Now when i try to run the application and test my database connectivity, then i get the error as mentioned below




my web.xml code



FindFile.java ( Took this file from the guide provided in HSQLDB1.8 download

path in the download is hsqldb\src\org\hsqldb\sample)





Man Suraj
Someone says "Impossible is nothing". The man next him says "Let me see you licking your elbow tip!"
Shailesh Chandra
Ranch Hand

Joined: Aug 13, 2004
Posts: 1081

Check the runtime path, It seems class jdbcDataSource is not there in runtime path.

Shailesh


Gravitation cannot be held responsible for people falling in love ~ Albert Einstein
Maan Suraj
Ranch Hand

Joined: Dec 20, 2007
Posts: 299
1) I have already given the path of jdbcDataSource in my "Path" and "ClassPath " environmental variable

Path = .;C:\hsqldb\src\org\hsqldb\jdbc;
Classpath = .;C:\hsqldb\src\org\hsqldb\jdbc;
jdbcDataSource is in C:\hsqldb\src\org\hsqldb\jdbc folder.

2) I also tried giving "C:\hsqldb\src" in my path and classpath as the jdbcDataSource.java file is in package org\hsqldb\jdbc
Kalyan Ram
Greenhorn

Joined: Dec 29, 2003
Posts: 14
http://hsqldb.org/doc/hsqlFindFile.html

The FindFile.java, in your post, isn't extending a Servlet. OTOH its got a main()

Am I missing something?


hth
/k

[ September 20, 2008: Message edited by: Kalyan Ram ]
[ September 20, 2008: Message edited by: Kalyan Ram ]
 
 
subject: NoClass definitopn found error