Static Cursors
Static cursors may detect their own updates, deletes, and inserts, although
they are not required to do so. Whether a particular static cursor detects these
changes is reported through the SQL_STATIC_SENSITIVITY option in SQLGetInfo. Static cursors never detect other updates, deletes, and inserts.
The row status array specified by the SQL_ATTR_ROW_STATUS_PTR statement
attribute can contain SQL_ROW_SUCCESS, SQL_ROW_SUCCESS_WITH_INFO, or SQL_ROW_ERROR
for any row. It returns SQL_ROW_UPDATED, SQL_ROW_DELETED, or SQL_ROW_ADDED for
rows updated, deleted, or inserted by the cursor, assuming that the cursor is
capable of detecting such changes.
Static cursors are commonly implemented by locking the rows in the result set
or making a copy, or snapshot, of the result set. While locking rows is
relatively easy to do, it has the drawback of significantly reducing concurrency.
Making a copy allows greater concurrency and allows the cursor to keep track of its
own updates, deletes, and inserts by modifying the copy. However, a copy is
more expensive to make and can diverge from the underlying data as that data is
changed by others.