OLE DB Programmer's Reference |
Returns information about the index rowset capabilities.
HRESULT GetIndexInfo ( DBORDINAL *pcKeyColumns, DBINDEXCOLUMNDESC **prgIndexColumnDesc, ULONG *pcIndexPropertySets, DBPROPSET **prgIndexPropertySets);
Parameters
The provider allocates memory for the structures and returns the address to this memory; the consumer releases this memory with IMalloc::Free when it no longer needs the structures. If *pcKeyColumns is zero on output or if an error occurs, the provider does not allocate any memory and ensures that *prgIndexColumnDesc is a null pointer on output.
For more information, see IIndexDefinition::CreateIndex.
The provider allocates memory for the structures and returns the address to this memory; the consumer releases this memory with IMalloc::Free when it no longer needs the structures. Before calling IMalloc::Free for *prgPropertySets, the consumer should call IMalloc::Free for the rgProperties element within each element of *prgPropertySets. The consumer must also call VariantClear for the vValue property of each DBPROP structure in order to prevent a memory leak in cases where the variant contains a reference type (such as a BSTR.) If *pcIndexPropertySets is zero on output or if an error occurs, the provider does not allocate any memory and ensures that *prgIndexPropertySets is a null pointer on output.
For information about the DBPROPSET and DBPROP structures, see "DBPROPSET Structure" and "DBPROP Structure" in Chapter 14: Properties.
Return Code
IDBProperties::GetPropertyInfo | IIndexDefinition::CreateIndex
1998-2001 Microsoft Corporation. All rights reserved.