Article ID: 156977
Article Last Modified on 11/21/2006
APPLIES TO
- Microsoft Foundation Class Library 4.2, when used with:
- Microsoft Visual C++ 4.2 Enterprise Edition
- Microsoft Visual C++ 4.2 Professional Edition
- Microsoft Visual C++ 4.2 Enterprise Edition
- Microsoft Visual C++ 4.2 Professional Edition
- Microsoft Visual C++ 5.0 Enterprise Edition
- Microsoft Visual C++ 5.0 Professional Edition
- Microsoft Visual C++ 6.0 Enterprise Edition
- Microsoft Visual C++ 6.0 Professional Edition
- Microsoft Visual C++ 6.0 Standard Edition
This article was previously published under Q156977
SYMPTOMS
You may continue to see deleted records when using the CRecordset and
CRecordView classes with a snapshot recordset.
CAUSE
The default behavior of the MFC ODBC classes has changed. It is now
possible to move onto a record that has been deleted. If the current
record has been deleted, the CRecordset IsDeleted() function will return
TRUE.
RESOLUTION
Open your CRecordset using the skipDeletedRecords option, or check
IsDeleted() to ensure that the current record is valid before using it.
STATUS
This behavior is by design.
REFERENCES
See the documentation for CRecordset::Open() and
CRecordset::IsDeleted(), as well as the MFC 4.2 Encyclopedia articles
entitled "Recordset: How Addnew, Edit, and Delete Work" and "Recordset:
Adding, Updating, and Deleting Records"
Additional query words: Move MoveFirst MoveLast MoveNext MovePrev kbvc420 kbvc500 kbvc600
Keywords: kbdatabase kbprogramming kbprb KB156977