CDaoRecordset Members

Base Class Members

Data Members

Construction

Attributes

Recordset Update Operations

Recordset Navigation Operations

Other Recordset Operations

Overridables

Base Class Members

CObject Members

Data Members

m_bCheckCacheForDirtyFields

Contains a flag indicating whether fields are automatically marked as changed.

m_nFields

Contains the number of field data members in the recordset class and the number of columns selected by the recordset from the data source.

m_nParams

Contains the number of parameter data members in the recordset class — the number of parameters passed with the recordset's query

m_pDAORecordset

A pointer to the DAO interface underlying the recordset object.

m_pDatabase

Source database for this result set. Contains a pointer to a CDaoDatabase object.

m_strFilter

Contains a string used to construct a SQL WHERE statement.

m_strSort

Contains a string used to construct a SQL ORDER BY statement.

Construction

CDaoRecordset

Constructs a CDaoRecordset object.

Close

Closes the recordset.

Open

Creates a new recordset from a table, dynaset, or snapshot.

Attributes

CanAppend

Returns nonzero if new records can be added to the recordset via the AddNew member function.

CanBookmark

Returns nonzero if the recordset supports bookmarks.

CanRestart

Returns nonzero if Requery can be called to run the recordset's query again.

CanScroll

Returns nonzero if you can scroll through the records.

CanTransact

Returns nonzero if the data source supports transactions.

CanUpdate

Returns nonzero if the recordset can be updated (you can add, update, or delete records).

GetCurrentIndex

Returns a CString containing the name of the index most recently used on an indexed, table-type CDaoRecordset.

GetDateCreated

Returns the date and time the base table underlying a CDaoRecordset object was created

GetDateLastUpdated

Returns the date and time of the most recent change made to the design of a base table underlying a CDaoRecordset object.

GetEditMode

Returns a value that indicates the state of editing for the current record.

GetLastModifiedBookmark

Used to determine the most recently added or updated record.

GetName

Returns a CString containing the name of the recordset.

GetParamValue

Retrieves the current value of the specified parameter stored in the underlying DAOParameter object.

GetRecordCount

Returns the number of records accessed in a recordset object.

GetSQL

Gets the SQL string used to select records for the recordset.

GetType

Called to determine the type of a recordset: table-type, dynaset-type, or snapshot-type.

GetValidationRule

Returns a CString containing the value that validates data as it is entered into a field.

GetValidationText

Retrieves the text that is displayed when a validation rule is not satisfied.

IsBOF

Returns nonzero if the recordset has been positioned before the first record. There is no current record.

IsDeleted

Returns nonzero if the recordset is positioned on a deleted record.

IsEOF

Returns nonzero if the recordset has been positioned after the last record. There is no current record.

IsFieldDirty

Returns nonzero if the specified field in the current record has been changed.

IsFieldNull

Returns nonzero if the specified field in the current record is Null (having no value).

IsFieldNullable

Returns nonzero if the specified field in the current record can be set to Null (having no value).

IsOpen

Returns nonzero if Open has been called previously.

SetCurrentIndex

Called to set an index on a table-type recordset.

SetParamValue

Sets the current value of the specified parameter stored in the underlying DAOParameter object

SetParamValueNull

Sets the current value of the specified parameter to Null (having no value).

Recordset Update Operations

AddNew

Prepares for adding a new record. Call Update to complete the addition.

CancelUpdate

Cancels any pending updates due to an Edit or AddNew operation.

Delete

Deletes the current record from the recordset. You must explicitly scroll to another record after the deletion.

Edit

Prepares for changes to the current record. Call Update to complete the edit.

Update

Completes an AddNew or Edit operation by saving the new or edited data on the data source.

Recordset Navigation Operations

Find

Locates the first, next, previous, or last location of a particular string in a dynaset-type recordset that satisfies the specified criteria and makes that record the current record.

FindFirst

Locates the first record in a dynaset-type or snapshot-type recordset that satisfies the specified criteria and makes that record the current record.

FindLast

Locates the last record in a dynaset-type or snapshot-type recordset that satisfies the specified criteria and makes that record the current record.

FindNext

Locates the next record in a dynaset-type or snapshot-type recordset that satisfies the specified criteria and makes that record the current record.

FindPrev

Locates the previous record in a dynaset-type or snapshot-type recordset that satisfies the specified criteria and makes that record the current record.

GetAbsolutePosition

Returns the record number of a recordset object's current record.

GetBookmark

Returns a value that represents the bookmark on a record.

GetPercentPosition

Returns the position of the current record as a percentage of the total number of records.

Move

Positions the recordset to a specified number of records from the current record in either direction.

MoveFirst

Positions the current record on the first record in the recordset.

MoveLast

Positions the current record on the last record in the recordset.

MoveNext

Positions the current record on the next record in the recordset .

MovePrev

Positions the current record on the previous record in the recordset.

Seek

Locates the record in an indexed table-type recordset object that satisfies the specified criteria for the current index and makes that record the current record.

SetAbsolutePosition

Sets the record number of a recordset object's current record.

SetBookmark

Positions the recordset on a record containing the specified bookmark.

SetPercentPosition

Sets the position of the current record to a location corresponding to a percentage of the total number of records in a recordset.

Other Recordset Operations

FillCache

Fills all or a part of a local cache for a recordset object that contains data from an ODBC data source.

GetCacheSize

Returns a value that specifies the number of records in a dynaset-type recordset containing data to be locally cached from an ODBC data source.

GetCacheStart

Returns a value that specifies the bookmark of the first record in the recordset to be cached.

GetFieldCount

Returns a value that represents the number of fields in a recordset.

GetFieldInfo

Returns specific kinds of information about the fields in the recordset.

GetFieldValue

Returns the value of a field in a recordset.

GetIndexCount

Retrieves the number of indexes in a table underlying a recordset.

GetIndexInfo

Returns various kinds of information about an index.

GetLockingMode

Returns a value that indicates the type of locking that is in effect during editing.

Requery

Runs the recordset's query again to refresh the selected records.

SetCacheSize

Sets a value that specifies the number of records in a dynaset-type recordset containing data to be locally cached from an ODBC data source.

SetCacheStart

Sets a value that specifies the bookmark of the first record in the recordset to be cached.

SetFieldDirty

Marks the specified field in the current record as changed.

SetFieldNull

Sets the value of the specified field in the current record to Null (having no value).

SetFieldValue

Sets the value of a field in a recordset.

SetFieldValueNull

Sets the value of a field in a recordset to Null. (having no value).

SetLockingMode

Sets a value that indicates the type of locking to put into effect during editing.

Overridables

DoFieldExchange

Called to exchange data (in both directions) between the field data members of the recordset and the corresponding record on the data source. Implements DAO record field exchange (DFX).

GetDefaultDBName

Returns the name of the default data source.

GetDefaultSQL

Called to get the default SQL string to execute.

See Also

Concepts

CDaoRecordset Class

Hierarchy Chart