List of OLE DB Consumer Templates

The OLE DB Consumer Templates contain the following classes. The reference material also includes topics on the macros for OLE DB Consumer Templates.

Session Classes

CDataSource

Corresponds to an OLE DB data source object, representing a connection through a provider to a data source. One or more database sessions, each represented by a CSession object, can take place on a single connection.

CEnumerator

Corresponds to an OLE DB enumerator object, which retrieves rowset information about available data sources.

CSession

Represents a single database access session. One or more sessions can be associated with each CDataSource object.

CEnumeratorAccessor

Used by CEnumerator to access the data from the enumerator rowset. This rowset consists of the data sources and enumerators visible from the current enumerator.

Accessor Classes

CAccessorBase

Base class for all accessor classes.

CAccessor

Used for records that are statically bound to a data source. Use this accessor class when you know the structure of the data source.

CDynamicAccessor

An accessor that can be created at run time, based on the column information of the rowset. Use this class to retrieve data if you don’t know the structure of the data source.

CDynamicParameterAccessor

An accessor that can be used when command types are unknown. Obtains the parameter information by calling the ICommandWithParameters interface, if the provider supports the interface.

CManualAccessor

An accessor with methods to handle both columns and command parameters. With this class, you can use any data types as long as the provider can convert the type.

Rowset Classes

CRowset

Used to manipulate, set, and retrieve rowset data.

CBulkRowset

Used to fetch and manipulate rows in bulk by retrieving multiple row handles with a single call.

CAccessorRowset

Encapsulates a rowset and its associated accessors.

CArrayRowset

Used to access elements of a rowset using array syntax.

IRowsetNotifyImpl

Provides a dummy implementation for IRowsetNotify, with empty functions for the IRowsetNotify methods OnFieldChange, OnRowChange, and OnRowsetChange.

CRestrictions

Used to specify restrictions for schema rowsets.

Schema Rowset Classes and Typedef Classes

The OLE DB Templates provide you with a set of classes that correspond to the OLE DB schema rowsets.

Command Classes

CCommand

Used to set and execute a parameter-based OLE DB command. To merely open a simple rowset, use CTable instead.

CTable

Used to access a simple rowset with no parameters.

CMultipleResults

Used as a template argument for the CCommand template when you want the command to handle multiple result sets.

CNoMultipleResults

Used as a template argument for the CCommand template when you want the command to handle a single rowset. CNoMultipleResults is the default value for the template argument.

CNoAccessor

Used as a template argument for template classes, such as CCommand and CTable, that take an accessor class argument. Use CNoAccessor if you do not want the class to support parameters or output columns.

CNoRowset

Used as a template argument for CCommand or CTable if the command or table does not return a rowset.

Property Classes

CDBPropIDSet

Used to pass an array of property IDs for which the consumer wants property information. The properties belong to one property set.

CDBPropSet

Used to set properties on a provider.

Bookmark Class

CBookmark

Used as an index for accessing data in a rowset.

Error Class

CDBErrorInfo

Used to retrieve OLE DB error information.

See also

List of OLE DB Provider Templates,