Home Answers Viewqa JDBC Not get ans properly

 
 


Abhijeet
Not get ans properly
3 Answer(s)      a year and 8 months ago
Posted in : JDBC

I create db on my system using MS-acess,then I create DSN for program but I still not get answer It throws an Exception "java.lang.classNotFoundException",what is this I don't get plz help me.

View Answers

September 6, 2011 at 11:05 AM


Create DSN connection:

1. Open Data Sources (Start->Control Panel->Administrative Tool->Data Sources(ODBC)
2. Open User DSN tab
3. Add a user DSN
4. Select Microsoft Access Driver(*.mdb)
5. Select database name and Create the DSN name (e.g emp)
6. Click "Ok" and then compile the following java code.

import java.sql.*;

public class CreateTable {
  public static void main(String[] args) throws Exception {
    Connection conn = DriverManager.getConnection("jdbc:odbc:student");
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    Statement st = conn.createStatement();
    st.executeUpdate("create table employee (empid int,empname varchar(30));");
    System.out.println("Table is created successfully!");
    st.executeUpdate("insert into employee (empid,empname ) values (1,'Roseindia')");
    System.out.println("Data is inserted successfully!");
    st.close();
    conn.close();
  }
}

September 10, 2011 at 1:04 PM


Yes sir I have done it & it compiled properly but when i run it Eception is come(java.lang.ClassNotFoundException:jdbc.odbc.JdbcOdbcDriver) what is this?I dont get plz tell me.


September 11, 2011 at 6:41 PM


Yes sir i got answer thank u very much









Related Pages:
Not get ans properly
Not get ans properly  I create db on my system using MS-acess,then I create DSN for program but I still not get answer It throws an Exception "java.lang.classNotFoundException",what is this I don't get plz help me.   
servlet not working properly ...pls help me out....its really urgent
servlet not working properly ...pls help me out....its really urgent  Hi, Below is the front page of my project 1)enty.jsp </form> <...;html> <body> > > <form method="post" action="get"> >
how to display jsp page containing mysql query in particular division using ajax ?my code is below bt i cundt get it properly
ajax ?my code is below bt i cundt get it properly   index.html <...; } } } request.open("GET", "newjsp.jsp", true); // Create a function...; } } } request.open("GET", "newjsp.jsp", true
implement internationlism in Flemish ans Spanish using Sturts1.1
implement internationlism in Flemish ans Spanish using Sturts1.1  HI - we are using struts1.1, we have a requirement to implement internationlism in Flemish ans Spanish. Will this be supported in Struts1.1? How to resolve
need to ans abt db - JSP-Servlet
need to ans abt db  helllo can you tell me m just starting to knowing abt servlet and i trying to making e-mail site so can you tell me with the java servlet wht is the backhand database to use to proper with that site
output not coming properly - JSP-Servlet
output not coming properly  I am not getting the output properly when i had written my code like below: Add Employee Details for( j=0;j<11;j++) { out.println("Department code
get
get ( ) Method in PHP  what is get method in PHP   Please visit the following link: http://www.roseindia.net/php/php-Get-Post.shtml
having problem with menu ans sub menu items css ...plz help!!
having problem with menu ans sub menu items css ...plz help!!  PLZ help ...this is my html menu > <div id="content"> <div > class="navigation" id="nav"> > <div class="item user"> >
Java Get Example
Java Get Example      ... Get examples like how to get the date and time, IP Address or memory size etc... examples to get the things fast and practice these code at your end to learn java
Design patterns interview questions2
;    Q9. What is Intercepting Filter pattern? Ans.... Servlet filters. Q10. What is Front Controller pattern? Ans. It manages and handles...? Ans. There generally are two parts to any application – the presentation
This Query is no working in sql developer it is giving Ora-0933 exception SQL command not properly ended exception
This Query is no working in sql developer it is giving Ora-0933 exception SQL command not properly ended exception  SELECT * from employees ORDER BY first_name limit 0,10;   Hi Friend, Please clarify your problem
Button text is not displaying properly in jre 1.6.0_22 when html tags are used in the textstring
Button text is not displaying properly in jre 1.6.0_22 when html tags are used in the textstring  using html string to jbutton text is not working in Java 1.6.0_22 when browser is using the existing java console this.setText
get and post
get and post  what is php and get   PHP get and post method
get method
get method   how to use get method: secure method is post method and most of use post method why use a get method
post get
post get  what is post and get
i have split a string by space ,done some operation and now how to properly order them for sending a mail in java or jsp - JSP-Servlet
i have split a string by space ,done some operation and now how to properly... that is not properly ordered i.e see the following ///I typed a matter like this in a text... for this month is 10000 .Thanks and Regards Hr . So how to properly set
It?s Easy to See Why You Should Learn PHP
The code of a website is important. It is used to get the site to run properly... to get a site to run properly and to ensure that a website can be safe and stable... as it possibly can. It will be easy for anyone to get a better looking site when PHP
POST or GET
POST or GET  hello, Which will execute faster on php POST or GET?   hii, The POST metod is much more faster then GET ..because in GET... to ULR that's why POST is faster then GET method
get Blob
get Blob   how i can display a Blob in XHTML (i developpe with hbernate
GPS fleet management solutions
Fleet owners look for GPS fleet management solutions to properly manage the functioning of their business. A proper management is necessary for the proper... and manger or owner can get every minute update with it. All these information
Social Media Marketing Tools
a social media marketing campaign properly is the only way to get the best possible... a marketing campaign properly. There is Sysomos that virtually provides... of these sites provides with this information, you can only get it from
Use of BasicConfigurator in Log4j logging
Please initialize the log4j system properly. If  you are getting foregoing log4j warn debug info, that means you have not initialized log4j properly. So... Please initialize the log4j system properly. It is because we don't have
Requirements for JSF to get started
Requirements for JSF to get started  What are the requirements for JSF to get started
Get the error messages displayed
Get the error messages displayed  How to get the error messages displayed
get absolute time java
get absolute time java  How to get absolute time in java
Hibernate get
In this section, you will learn about get method of Hibernate
advantages of get method?
advantages of get method?  php in what is advatages of get methods and how you can use get methods
Get Image
Get Image       This Example shows you get the image. Description of the code...; is set to true.getDefaultToolkit is used for get the default toolkit
property in javascript get set
property in javascript get set  How to create the get and set property in JavaScript?   Creating Get and Set properties in JavaScript example.. myVar Sample = { nval : "", get get() { return this.nval; }, set
post ,get data in the database
post ,get data in the database  post ,get data in the database  Please visit the following links: PHP get post data PHP Tutorials
$_get php example - PHP
$_get php example  Explain the $_get method in php with a simple example. m a beginner
Get image color
Get image color  How to get image color in iPhone SDK application
java get file permission
java get file permission  How to check the get file permission in Java
Get GMT from IP
Get GMT from IP  How do I get GMT value from IP address?? Thanx in Adv
GET and POST methods
GET and POST methods   What are the differences between GET and POST methods in form submitting, give the case where we can use GET and we can use POST methods
jQuery ajax get example
jQuery ajax get example  Hi, How I can use jQuery for get request? Give me code for jQuery ajax get request. Thanks
why get method is used?
why get method is used?  why get method is used in 60% commercial application while using post is more secure
What Functions Can the iPad Handle?
of the package and has it properly activated can take advantage of a large number... with the iPad when it is being handled. It is incredibly easy to get... many formats including the MP3 and Apple Lossless formats. It can also get new
question for "get method"
question for "get method"  when I want make method "get" for name or any char or string ..how I can write the syntax ? and what does it return
Get the list of tables in Sybase
Get the list of tables in Sybase   hello, How to get the list of tables in Sybase?   hii, Select name from sysobjects where type="...." it will give You list according to where clause
The $_GET Function
The $_GET Function The $_GET function in PHP is used to gather data of form submit with method="get". The data sent using get method is visible.... Given below form uses get method for sending data : <form action="
how to get following output
how to get following output  input 123456 output 1 2 3 4 5 6
Get session value in javascript
Get session value in javascript   How to iterate session value onebyone in JavaScript
get ting this Exception - EJB
get ting this Exception  Root exception is javax.naming.NameNotFoundException: Unable to resolve 'PTASessionBean'. Resolved '']; remaining name 'PTASessionBean

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.