sun.jdbc.odbc.jdbcodbcdriver <-- this is the fully
qualified name of a class..this class also happens to
be the implementation of the JDBC-ODBC driver which is
shipped defaullt in the JDK kits from sun.
If I have written my own implementation of a JDBC
Driver and named the class as cm.vijay.MyDriver then
my code will be
Class.forName("com.vijay.MyDriver");
Also an observation ...it is a good practice to call
the newInstance() so that the call will look like
Class.forName("sun.jdbc.odbc.jdbcodbcdriver").newInstance();
I have read reports that some of the JVM's have a bug
that does not properly execute static blocks....ans
the call to newInstance() will make them execute
properly.
With respect to the DriverManger..this classes fully
Qualified name is
java.sql.DriverManager
<Taken From the JDK Docs>
<Start>
As part of its initialization, the DriverManager class
will attempt to load the driver classes referenced in
the "jdbc.drivers" system property. This allows a user
to customize the jdbc Drivers used by their
applications. For example in your
~/.hotjava/properties file you might specify:
jdbc.drivers=foo.bah.Driver:wombat.sql.Driver:bad.taste.ourDriver
A program can also explicitly load JDBC drivers at
any time. For example, the my.sql.Driver is loaded
with the following statement:
Class.forName("my.sql.Driver");
When the method getConnection is called, the
DriverManager will attempt to locate a suitable driver
from amongst those loaded at initialization and those
loaded explicitly using the same classloader as the
current applet or application.
</END>
</Taken From the JDK Docs>