In OLE DB, a data source object is a COM object through which a consumer connects to a provider's underlying data store.
It is important to distinguish a provider's data source object, which provides data from the data store to a consumer, from the data store itself, which contains the data but interacts with the consumer only through the data source object. For example, a data store might be a comma-separated-value (CSV) text file, an SQL DBMS, or an in-memory array in an application.
The data source object cotype is defined as follows. For more information about cotypes, see "Conceptual Programming Models in OLE DB" in Chapter 1: Overview of OLE DB.
CoType TDataSource {
[mandatory] interface IDBCreateSession;
[mandatory] interface IDBInitialize;
[mandatory] interface IDBProperties;
[mandatory] interface IPersist;
[optional] interface IConnectionPointContainer;
[optional] interface IDBAsynchStatus;
[optional] interface IDBDataSourceAdmin;
[optional] interface IDBInfo;
[optional] interface IPersistFile;
[optional] interface ISupportErrorInfo;
}
For information about the registry entries used by providers to register classes of data source objects, see "Provider Registry Entries" in Chapter 18: Programming Considerations.