SQL Server 2000 Books Online contains a section titled "Rowsets and SQL Server Cursors" which states that setting the following rowset properties for the SQL Server OLE DB Provider (SQLOLEDB) is equivalent to a fast-forward cursor:
DBPROP_SERVERCURSOR = true
DBPROP_DEFERRED = false
DBPROP_IRowsetChange = false
DBPROP_IRowsetLocate = false
DBPROP_IRowsetScroll = false
DBPROP_IRowsetUpdate = false
DBPROP_BOOKMARKS = false
DBPROP_CANFETCHBACKWARDS = false
DBPROP_CANSCROLLBACKWARDS = false
DBPROP_CANHOLDROWS = false
DBPROP_LITERALBOOKMARKS = false
DBPROP_OTHERINSERT = true
DBPROP_OTHERUPDATEDELETE = true
DBPROP_OWNINSERT = true
DBPROP_OWNUPDATEDELETE = true
DBPROP_QUICKRESTART = false
DBPROP_IRowsetResynch = false
DBPROP_CHANGEINSERTEDROWS = false
DBPROP_SERVERDATAONINSERT = false
DBPROP_UNIQUEROWS = false
DBPROP_REMOVEDELETED = false
However, if all of these properties are set and a rowset contains a "text", "ntext", or "image" column data type, the following error will be returned from the
ICommand::Execute call:
HRESULT = 0x80040e21 (DB_E_ERRORSOCCURRED)
Description = "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done."
A call to
ICommandProperties::GetProperties() to retrieve the properties which could not be set (using DBPROPSET_PROPERTIESINERROR) will show that the DBPROP_OTHERINSERT property caused the error.