O'Reilly logo

J2EE™ and Beyond: Design, Develop, and Deploy World-Class Java™ Software by Art Taylor

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using JDBC

The best place to start in understanding an API is with a minimal implementation example. The following code demonstrates just such an implementation using only four JDBC classes as listed in Table 5-4.

Table 5-4. Core JDBC Classes
Interface/ClassPurpose
DriverManagerLoads the JDBC driver and manages the database connection. Controls access to the database driver.
ConnectionConnects to the database and allows the creation of Statement objects.
StatementAllows the execution of SQL statements and returns results, either integer values for the number of rows updated or ResultSet objects representing the rows returned by the execution of a SQL select statement.
ResultSet Allows access to individual rows in the set of rows returned by a SQL ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required