Share via


CDatabase::GetCursorRollbackBehavior

int GetCursorRollbackBehavior( ) const;

Return Value

A value indicating the effect of transactions on open recordset objects. For details, see Remarks.

Remarks

Call this member function to determine how a Rollback operation affects cursors on open recordset objects.

The following table lists the possible return values for GetCursorRollbackBehavior and the corresponding effect on the open recordset.

Return value Effect on CRecordset objects
SQL_CB_CLOSE Call CRecordset::Requery immediately following the transaction rollback.
SQL_CB_DELETE Call CRecordset::Close immediately following the transaction rollback.
SQL_CB_PRESERVE Proceed normally with CRecordset operations.

For more information about this return value, see the ODBC API function SQLGetInfo in the ODBC SDK Programmer's Reference. For more information about transactions, see the article in Visual C++ Programmer's Guide.

CDatabase OverviewClass MembersHierarchy Chart

See Also   CDatabase::GetCursorCommitBehavior, CDatabase::CanTransact, CDatabase::BeginTrans, CDatabase::CommitTrans, CDatabase::Rollback, CRecordset