Appendix A: Providers
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 in conjunction with other service providers or components.
Data Providers
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.
Area | Topic |
---|---|
ODBC databases | Microsoft OLE DB Provider for ODBC |
Microsoft Indexing Service | Microsoft OLE DB Provider for Microsoft Indexing Service |
Microsoft 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 |
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 object's Properties collection to obtain the provider-specific properties. Refer to the provider documentation and the OLE DB Programmer's Reference for detailed information about these dynamic properties.
Service Providers
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 of the service providers currently available from Microsoft:
- Microsoft Data Shaping Service for OLE DB
- Microsoft OLE DB Persistence Provider
- Microsoft OLE DB Remoting Provider
Service Components
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 providers, see the documentation for Microsoft OLE DB in the Microsoft Data Access Components SDK or visit the Microsoft Universal Data Access Web site.
Provider Commands
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
statement, such as, DROP TABLE t1
, as part of the user
input.
See Also
Command Object | Connection Object | 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 | OLE DB Provider for Microsoft Jet | Properties Collection | Recordset Object | Refresh Method (RDS)