LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-20-2011, 01:08 AM   #1
sisirkumar
LQ Newbie
 
Registered: Feb 2011
Posts: 8
Blog Entries: 1

Rep: Reputation: 0
jdbc connectivity


well, i have installed suse linux 11.3.
i have jdk 1.6.20.0 and oracle 10g 10.2.0.
when i tried to connect to a database through thin driver ,it is giving me the following error.
Exception in thread "main" java.lang.NoClassDefFoundError: odata
Caused by: java.lang.ClassNotFoundException: odata
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
Could not find the main class: odata. Program will exit.

could anyone please answer this question?
it is urgent
 
Old 04-20-2011, 01:26 AM   #2
paulsm4
LQ Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
This isn't a JDBC problem, it isn't a database connectivity problem.

Your Java runtime simply can't find class "odata"

Your "java" command line might be messed up, you might not have the right classpath - or maybe "odata" simply doesn't exist.

You need to find "odata" to resolve the problem.
 
Old 04-21-2011, 10:17 AM   #3
sisirkumar
LQ Newbie
 
Registered: Feb 2011
Posts: 8
Blog Entries: 1

Original Poster
Rep: Reputation: 0
problem in classpath setting

Quote:
Originally Posted by paulsm4 View Post
This isn't a JDBC problem, it isn't a database connectivity problem.

Your Java runtime simply can't find class "odata"

Your "java" command line might be messed up, you might not have the right classpath - or maybe "odata" simply doesn't exist.

You need to find "odata" to resolve the problem.
could you please tell me how do i setup the classpath of the ojdbc14.jar in order to have the database connectivity.
 
Old 04-21-2011, 10:26 AM   #4
rahulkya
Member
 
Registered: Feb 2009
Location: New Delhi
Distribution: Linux mint,Ubuntu,Debian,RHEL 5,slackware 13.1, free BSD,solaris.
Posts: 186
Blog Entries: 3

Rep: Reputation: 33
execute the following command from terminal...
Quote:
export CLASSPATH=/Path_to_your_odbc_jar/ojdbc14.jar:$CLASSPATH
then try to compile or run the file
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Outgoing Connectivity problems. Incoming connectivity fine Fionnbharr Linux - Newbie 1 10-02-2008 01:51 PM
JDBC vs Perl gliesian Linux - Security 2 04-27-2008 03:44 PM
JDBC-ODBC connectivity problem rajivb Programming 3 03-09-2005 11:22 AM
Jdbc apffal Linux - General 0 10-07-2004 01:37 PM
help with my JDBC Driver working2hard Programming 2 07-27-2004 11:18 AM


All times are GMT -5. The time now is 02:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration