1600 PMP mock questions | 1400 CAPM mock questions | 800 SCJP 6 mock questions | 600 OCAJP 7 mock questions | 590 OCPJP 7 mock questions | 556 SCWCD 5 mock questions | 500 OCEJWCD 6 mock questions | pdfDownload (java,struts, hibernet etc) |
Java online test
JSP online test ORACLE online test Hibernate online test Servlet online test Struts online test EJB online test C online test C++ online test Aptitude online test |
Q.What are the steps in the JDBC connection?
|
|
While making a JDBC connection we go through the following steps :
Step 1 : Register the database driver by using : Class.forName(\" driver classs for that specific database\" ); Class.forName("com.mysql.jdbc.Driver"); Step 2 : Now create a database connection using : Connection con = DriverManager.getConnection(url,username,password); Connection con = DriverManager.getConnection("jdbc:mysql://localhost:3306/art",art,art); Step 3: Now Create a query using : Statement stmt = Connection.Statement(\"select * from EMP\"); Step 4 : Exceute the query : ResultSet rs = stmt.exceuteQuery(); while(rs.next()){ System.out.println(rs.getString(1)); } |
||
Online Practice TestJava online testJSP online test ORACLE online test Hibernate online test Servlet online test Struts online test EJB online test C online test C++ online test Aptitude online test |
Reviews and Comments
PMP, CAPM, PMI is a registered certification mark of the Project Management Institute, Inc
Copyright © www.techfaq360.com 2019