Share via


msDataSourceObject

The msDataSourceObject method described below should be used only when the provider is being written in Microsoft? Visual Basic? or Microsoft Visual J++?. Implement msDataSourceObject in your provider code using the appropriate IDispatch methods.

If you are writing a provider in Visual Basic, msDataSourceObject provides the mechanism by which an OLE DB rowset maps to the correct OSP implementation. The method accepts a string parameter indicating the correct OSP and returns a pointer to that OSP (which you will then invoke using the standard IDispatch::Invoke call). See the supplied Visual Basic code samples for an example.

The signature for msDataSourceObject is as follows:

Important

This feature will be removed in a future version of Windows. Avoid using this feature in new development work, and plan to modify applications that currently use this feature. Instead, write a fully functional OLE DB provider using the native OLE DB interfaces.

Syntax

HRESULT msDataSourceObject(
   BSTR      qualifier,
   LONG    **ppUnk);

Parameters

  • qualifier
    [in] Identifier for a data set when there is more than a single data source. When the parameter is NULL or a null string ("") is used, the data interface on the default data set should be returned. This string is interpreted as case-insensitive.

  • **ppUnk
    [out] Interface pointer to the specified OSP implementation.