Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

what exactly happens when we execute
"Class.forname("Driver class name");"?Explain indetail

Answer Posted / sudhakar

By the end of the execution of Class.forName("Driver
class"); the driver class should be loaded into the memory
but also
1. The driver class should be initialized
2. Should be registered with the driver manager class
The above two operations are not done by forName() . So a
pure Static() block is defined in which the above two tasks
are manipulated and by which we are able to get connection,
immediately after loading the driver class without writing
any code to initialize the driver class.

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a jdbc connection?

943


Is jdbc part of j2ee?

1032


What does executequery return in java?

980


What types of DataSource objects are specified in the Optional Package?

1060


Which of the attributes in the monitoring tab for a jdbc connection pool in the administrative console tell us how many clients are currently waiting for a connection?

971


How to test jdbc connection to sql server?

1065


What is the use of dialect?

1059


Expalin the method of calling a stored procedure from jdbc.

1013


Discuss the procedure of retrieving warnings?

1031


What does adapter class provide?

994


How to set the attribute concurrency in resultset?

969


How to check jdbc connection in linux?

1070


What are the 4 types of jdbc drivers?

1088


Why jdbc is used in java?

1001


What are the steps to connect to the database in java?

1030