This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes JDBC and the fly likes DriverManager class Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Databases » JDBC
Reply Bookmark "DriverManager class" Watch "DriverManager class" New topic
Author

DriverManager class

MaheshS Kumbhar
Ranch Hand

Joined: Sep 24, 2009
Posts: 188
I referred one URL http://java.sun.com/j2se/1.5.0/docs/guide/jdbc/getstart/drivermanager.html#999674

In this, I read that DriverManager class handles establishing connection between a database and appropriate driver.
But what my intuition is, the connection is established between an application and database.

Correct me if I am wrong.


I am slow but sure
Jan Cumps
Bartender

Joined: Dec 20, 2006
Posts: 2343

the connection is established between an application and database
Indeed. But by using the DriverClass, and othe jdbc classes, as the connection mechanism.

Your application asks the DriverClass to connect to the database.
The DriverClass establishes the connection to the database.
Your application uses that connection.


OCUP UML fundamental
ITIL foundation
MaheshS Kumbhar
Ranch Hand

Joined: Sep 24, 2009
Posts: 188
Thanks Jan
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: DriverManager class
 
Similar Threads
Java Class Implementation Logic
database url
Connecting to MS Access
DriverManager class
why should dataSource be used instead of Device Manager