Answer Posted / raghavendra desai
when the Class.forName("oracle.jdbc.driver.OracleDriver) is
executed, the driver calss will be loaded if it was not
loaded earlier. As soon as the class is loaded the static
block will be executed. In the static block the JDBC driver
vendors are responsible for providing the static block in
the driver class. In static block they would have been
written the similar kind of code.
public class oracle.jdbc.driver.OracleDriver implements
Driver
{
static
{
Driver drv= new oracle.jdbc.driver.OracleDriver();
DriverManager.registerDriver(drv)
-----
-----
some other code
}
}
| Is This Answer Correct ? | 36 Yes | 3 No |
Post New Answer View All Answers
Can you control when passivation occurs?
whats is mean by tiles in struts
What is colon_pkg_prefixes and what is its use?
What state does a thread enter when it terminates its processing?
What is difference between object state and behavior?
Difference between swing and awt?
What are externizable interface?
what are memory considerations of jsp compares to other web components?
What is the difference between session and entity beans?
What is the difference between ear, jar and war file?
cud u help me ... i am struggling with this question... to find all the subsets of a given set for ex.... a,,b,c shud give all the subsets.... i gt the program in c bt nt able to get it in java..... help needed ..
What is a sessionfactory? Is it a thread-safe object?
how to use debug in my elipse to solve problems that exist in my project
What do you know about seam?
AS a developer will u create a data source in connection pool? If so how will u do that, how to access the object from connection pool using IRAD tool?