JDBC Imports

Every application that uses the JDBC API needs to include a number of import statements at the beginning of the program. These imports are required for the javac program to resolve JDBC references. The import libraries are listed in the following table. Note that at a minimum, the java.sql.* import is required.

Table 9-1. JDBC Import Statements
ImportDescription
java.sql.*This import is required for the core JDBC API and should be included in every program that uses JDBC.
javax.sql.*This library is required for enterprise server-side support.
java.io.*This library is required for any streaming of BLOB or CLOB objects.
java.math.*This library is required for any BigDecimal support (NUMERIC and DECIMAL columns).
java.text.*This library provides ...

Get Apache Derby—Off to the Races: Includes Details of IBM® Cloudscape™ now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.