What does Class.forName return?

Answer Posted / prashant

Class.forNmae first loads the class in current classLoader so as to use that in future. Internally DriverManager gets the reference of the driver by using dynamic laoding (nothing is magical) this is is the reason when you say manager.GetConnection() it returns connection using the loaded driver

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can we retrieve the file in the oracle database?

512


What is jdbc explain?

494


What is 2 phase commit?

558


What does the jdbc driver interface do?

548


What does executequery return in java?

509






What are common JDBC Exceptions?

546


What do you mean by two phase commits?

563


Give an example of code used for setting up connection with a driver.

517


What is SQL Warning? How to retrieve SQL warnings in the JDBC program?

543


Which Java and java.sql data types map to my specific database types?

538


How do I check in my code whether a maximum limit of database connections have been reached?

581


How MS-Access DB can be accessed over a network, using JDBC API?

2017


What are the considerations for deciding on transaction boundaries?

558


Which database is used with java?

497


Which jdbc driver type s is are the jdbc odbc bridge?

474