Chapters

OLE DB Programmer's Reference

Chapters are used to identify a group of rows within a rowset. The group of rows may have a common characteristic, such as satisfying a filter condition or having a common parent in a hierarchical rowset, and may have an imposed order. Chapter handles are defined as follows:

typedef ULONG_PTR HCHAPTER;

Because chapters have significant overhead, they must be managed. This is done automatically according to the following rules:

  • The rules for sequential rowsets take precedence, so a grouped sequential rowset's chapters can be opened only in the proper sequence and cannot be revisited after they have been scanned. It might be necessary to close a prior chapter before the next can be opened.
  • A chapter is opened upon use, if it is not already in an active state.

When the reference count on a chapter is released to zero, the resources needed to manage the chapter can be discarded or marked as eligible for discard. However, if the reference count on a chapter falls to zero and the chapter contains rows with pending changes, the chapter's resources might not be freed until the pending change status on the rows is cleared through a call to either IRowsetUpdate::Update or IRowsetUpdate::Undo.

1998-2001 Microsoft Corporation. All rights reserved.



Microsoft Ole Db 2.0 Programmer's Reference and Data Access SDK
Microsoft OLE DB 2.0 Programmers Reference and Data Access SDK (Microsoft Professional Editions)
ISBN: 0735605904
EAN: 2147483647
Year: 1998
Pages: 1083

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net