ODBC's structural model ODBC structure includes four main parts: application interface, drive manager, database driver, and data source. Application Interface: The difference between the function call between the masked ODBC database driver provides a unified SQL programming interface for users. Drive Manager: Load the database driver for the application. Database driver: Implement ODBC function calls, providing SQL requests for a particular data source. If desired, the database drive will modify the application's request, so that the information supported by the relevant DBMS is requested. Data Source: The data you want to access and consist of the operating system, DBMS, and network platforms used to access DBMS.
The JDBC API is described as a set of abstract Java interfaces. It is similar to the application to open a database, execute the SQL statement and processes the result. The most important interface is: * Java.sql.driverManager Processing Driver Tuning and supports new database connections. * Java.sql.connection represents the connection to a particular database. * Java.sql.Statement represents a specific container to perform SQL statements for a specific database. * Java.sql.ResultSet Controls access to row data for a particular statement. Among them, java.sql.statement has two subtypes: 1. Java.sql.preparedStatement is used to perform pre-compiled SQL statements. 2. Java.sql.callableStatement is used to perform calls to the embedded process in a database.