Dao(Data accessobjects)The data access object is used to expose the Microsoft Jet Database Engine.
And allows developers to directly connect to other databases through ODBC.
Access Table. Dao
It is most suitable for single-system applications or small-scale local distribution. Its internal access to the Jet Database has been accelerated and optimized, and it is also very convenient to use. Therefore, if the database is an Access database and is used locally, we recommend that you use this access method-application uniqueness.
Rdo (remote
Data Objects)The remote data object is an ODBC-oriented data access interface, which is the same as the easy-to-use DAO
Styles are combined to provide an interface to demonstrate the underlying functions and flexibility of all ODBC databases. Although rdo is restricted in its access to jet or isam databases, it can only access relational databases through the existing ODBC driver. However, rdo has been proven to be a lot of SQL
Server, Oracle
And the best interfaces frequently used by developers of large relational databases. Rdo provides more complex objects, attributes, and methods used to access stored procedures and complex result sets. --- It is undoubtedly based on ODBC
ADO (ActiveX
Data Object)Is the successor of Dao/rdo. ADO
2.0 more functionally similar to rdo, and generally there is a similar ing between the two models. Ado "extends" Dao and
The object model used by rdo, which means it contains fewer objects, more attributes, methods (and parameters), and events.
As the latest database access mode, ADO is also easy to use, so Microsoft has clearly stated that it will focus on ADO in the future and will not upgrade Dao/rdo, therefore, ADO has become the mainstream of database development.
Ado involves data storage: DSN (data source name), ODBC (open data connection), and Ole
DB methods. --- It can be said that it is the integration of system-level programming interfaces such as ODBC and oledb, and the upgrade of application-level programming interfaces such as Dao and rdo. (We will detail VB's ado-based data access in the next article ).
ODBC (Open Database Connectivity)Open Database interconnection)
Some databases that comply with the standards and specifications can be operated through commands written by SQL (Structured Query Language. understanding ODBC is a standard for database interconnection. ODBC configuration in Windows is the same as registering a database in the system. he is also the predecessor of ADO!
OLE DB
Is Microsoft
A strategic system-level programming interface for managing data within the entire organization. OLE DB
Is created in ODBC
Function. ODBC
It is specially developed to access relational databases, and ole db is used to access relational and non-relational information sources, such as the host isam/VSAM
And hierarchical databases, email and file system storage, text, graphics and geographic data, and custom business objects.
OLE DB
Defines a group of COM
Interfaces, encapsulate various database management system services, and allow the creation of software components to implement these services.OLE DBComponents include data providers (including and displaying data), data users (using data), and service components (processing and transmitting data, such as query processors and cursor engines ).
In addition, OLE DB
Contains a connection to ODBC
"Bridge", for the current use of a variety
ODBC relational database drivers provide consistent support. --- Claim to replace ODBC, but also compatible with ODBC
Let's just say,We operate on ado, and ADO accesses oledb (of course we can access other ones, as long as they comply with the ADO Interface), oledb queries ODBC (or you don't need to look for him ).Obtain the operation data of the data interface, that is, oledb is located between the ODBC layer and the application.
Your ADO call is first sent to oledb and then processed by ODBC..
You can also directly connect to the oledb layer.
Next, let's talk about how to directly connect the Access database to oledb: (as for the connection method to SQL, I will add it later)
Create an object first:
Dim objcn as new connection
Then use the following connection string:
Objcn. connectionstring = "provider = Microsoft. Jet. oledb.4.0 ;"&_
"Datasource =" & App. Path & "\ instance 1.mdb"
Objcn. Open
The above are some of the conceptual problems encountered in the recent study of "let alone three things". The specific operation steps will be presented to you in the next step!