This section addresses three kinds of providers: data providers, service providers, and service components. Providers fall into two categories: those providing data and those providing services. A data provider owns its own data and exposes it in tabular form to your application. A service provider encapsulates a service by producing and consuming data, augmenting features in your ADO applications. A service provider may also be further defined as a service component, which must work together with other service providers or components.
ADO is powerful and flexible because it can connect to any of several different data providers and still expose the same programming model, regardless of the specific features of any given provider.
However, because each data provider is unique, how your application interacts with ADO will vary slightly by data provider. The differences usually fall into one of three categories:
Connection parameters in the ConnectionString property.
Command object usage.
Provider-specific Recordset behavior.
Details for each of the data providers currently available from Microsoft are listed as follows.
|ODBC databases||Microsoft OLE DB Provider for ODBC|
|Microsoft Indexing Service||Microsoft OLE DB Provider for Microsoft Indexing Service|
|Active Directory Service||Microsoft OLE DB Provider for Microsoft Active Directory Service|
|Microsoft Jet databases||OLE DB Provider for Microsoft Jet|
|Microsoft SQL Server||Microsoft OLE DB Provider for SQL Server|
|Oracle databases||Microsoft OLE DB Provider for Oracle|
|Internet Publishing||Microsoft OLE DB Provider for Internet Publishing|
|Simple data sources||Microsoft OLE DB Simple Provider|
Provider-Specific Dynamic Properties
The Properties collections of the Connection, Command, and Recordset objects include dynamic properties specific to the provider. These properties provide information about functionality specific to the provider beyond the built-in properties that ADO supports.
After establishing the connection and creating these objects, use the Refresh method on the Properties collection of the object to obtain the provider-specific properties. Refer to the provider documentation and the OLE DB Programmer's Guide for detailed information about these dynamic properties.
To use a service provider, you must supply a keyword. You should also be aware of the provider-specific dynamic properties associated with each service provider. Provider-specific details are listed for each service provider that is currently available from Microsoft:
The Cursor Service for OLE DB service component supplements the cursor support functions of data providers. It also requires a keyword and has dynamic properties.
For more information about OLE DB Providers, see Microsoft OLE DB.
For each provider listed here, if your applications allow users to enter SQL statements as the provider commands, you must always validate the user input and be vigilant of possible hacker attacks using potentially dangerous SQL statements, such as
DROP TABLE t1, as part of the user input.
Command Object (ADO) Connection Object (ADO) Microsoft OLE DB Provider for Internet Publishing Microsoft OLE DB Provider for Microsoft Active Directory Service Microsoft OLE DB Provider for Microsoft Indexing Service Microsoft OLE DB Provider for ODBC Microsoft OLE DB Provider for Oracle Microsoft OLE DB Provider for SQL Server Microsoft OLE DB Provider for Microsoft Jet Properties Collection (ADO) Recordset Object (ADO) Refresh Method (RDS)