Summary

This chapter showed you the second of the seven major components of ActiveX Data Objects, the Recordset object and its functions. After reading this chapter, you should be able to fully understand the Recordset object and the following key points:

  • There are four different types of views, or cursors, into a data source’s information. These are the dynamic, keyset, static, and forward-only cursors.

  • Recordsets are opened with the Open method. Before a recordset is opened, the way in which it can be opened can be fine-tuned with multiple properties, and once a recordset is opened, it can be filtered and sorted.

  • The standard ways in which you can move around within a recordset are the MoveFirst, MovePrevious, MoveNext, and MoveLast methods. In addition, the record pointer can be set to a particular ordinal position within a recordset or a valid bookmark.

  • Records can be added, modified, and deleted. The status of a particular record can be identified -- and multiple records can be returned -- by the single method calls GetRows and GetString.

  • There are four different types of record-locking schemes: read-only, pessimistic, optimistic, and batch optimistic record locking.

The next chapter of this book, Chapter 6, explains how to work with individual fields of a recordset. In addition, this chapter will show how these fields can be manipulated from within an application.

Get ADO: ActiveX Data Objects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.