Java Enterprise in a Nutshell (In a Nutshell (OReilly))
The JDBC[*] API provides Java applications with midlevel access to most database systems, via the Structured Query Language (SQL). JDBC is a key enterprise API, as it's hard to imagine an enterprise application that doesn't use a database in some way. [*] According to Sun, "JDBC" is not an abbreviation for "Java Database Connectivity." In the first two editions of this book, we focused on the original JDBC 1.0 and 2.0 APIs. As of J2SE 1.4, the JDBC 3.0 API became part of the standard Java deployment, so we've reworked this chapter to focus on the JDBC 3.0 API, which includes a modest yet valuable set of new features. Some JDBC 3.0 features aren't yet widely implemented (or aren't supported by some underlying databases ), so we'll call special attention to them. Since JDBC has been around for so long (it even predates the J2EE abbreviation), the different versions can get a little confusing. A number of JDBC 2.0 features were found in the JDBC 2.0 Optional Package and distributed as part of the javax.sql package rather than regular JDBC's java.sql package. JDBC 3.0 has merged everything back into a single specification, where it will hopefully remain. A word of caution: while the java.sql package is not tremendously complex, it does require grounding in general database concepts and the SQL language itself. This book includes a brief SQL reference (see Appendix D), but if you have never worked with a relational database system before, this chapter is not the place to start. For a more complete treatment of JDBC and general database concepts, we recommend Database Programming with JDBC and Java by George Reese (O'Reilly). |