What is JDBC? JDBC, called Java Database Connectivity Standard, is an object-oriented application interface (API) through which you can access a variety of relational databases. JDBC is also part of the Java Core Class library.The most important feature of JDBC is that it is independent of the detailed relational database. Similar to ODBC (Open Database Connectivity), some Java classes are defined in the JDBC API to represent a connection to a database (connections), an SQL statement (SQL statements), a result set (results Sets) and other database objects make it easy for Java programs to interact with the database and process the resulting results. With JDBC, all Java programs (including Java applications, applets, and Servlets) can access the database through SQL statements or procedures stored in the database (stored procedures). To access a particular database through JDBC. The corresponding JDBC driver must be available. It is often provided by the manufacturer of the production database and is the bridge between the JDBC API and the detailed database.
Usually. The Java program first uses the JDBC API to interact with the JDBC Driver Manager, and the JDBC Driver Manager loads the specified JDBC drivers, which can later access the database through the JDBC API. ODBC (Open database Connectivity) is an integral part of the database in the Microsoft Open Services Architecture (Wosa,windows Open service Architecture). It establishes a set of specifications and provides a set of standard APIs (application programming interfaces) for access to the database. These APIs use SQL to complete most of their tasks. ODBC itself also provides support for the SQL language, allowing users to send SQL statements directly to ODBC.
An ODBC-based application that operates on a database does not rely on any DBMS, does not interact directly with the DBMS, and all database operations are completed by the corresponding DBMS's ODBC driver. Other words. Whether it is FoxPro, access, or Oracle database, you can use the ODBC API for an interview.
Thus. The best advantage of ODBC is the ability to handle all databases in a unified manner. A complete ODBC consists of the following parts: Application (Application).
ODBC Administrator (Administrator). The program is located within the 32-bit ODBC of the Windows 95 Control Panel. Its primary task is to manage installed ODBC drivers and manage data sources. Driver Manager (Driver Manager).
The driver manager is included in the ODBC32.DLL. is transparent to the user.
Its task is to manage the ODBC driver, which is the most important part of ODBC. ODBC API.
ODBC driver. is a number of DLLs that provide an interface between ODBC and the database. The data source. The data source includes information such as database location and database type. is actually an abstraction of a data connection.
The relationships between the components you see: An application needs to access a database, first of all, you must register a data source with the ODBC Administrator. The manager establishes the connection between ODBC and the detailed database according to the database location, database type and ODBC driver provided by the data source. This allows the application to establish a connection to the corresponding database simply by providing the data source name to the ODBC,ODBC.
In ODBC, the ODBC API cannot directly access the database. Information must be exchanged with the database through the driver manager. The driver manager is responsible for passing the application's call to the ODBC API to the correct driver, while the driver finishes the corresponding operation. Returns the results to the application through the driver manager. ODBC driver support is required for access to ODBC data sources. With Visual C + + 5.0 Setup, you can install drivers such as SQL Server, Access, Paradox, DBase, FoxPro, Excel, Oracle, and Microsoft text. By default, VC5.0 only installs drivers for SQL Server, Access, FoxPro, and dBASE. Assuming that the user needs to install another driver, you need to execute the VC 5.0 Setup program again and select the desired driver.
JDBC and ODBC differences, sentiment, learning ...