Returns a list of snapshots that are currently active.
sa_snapshots( )
Column name | Data type | Description |
---|---|---|
connection_num | INT | The connection ID for the connection on which the snapshot is running. |
start_sequence_num | UNSIGNED BIGINT | A unique number that identifies the snapshot. |
statement_level | BIT | True if the snapshot was created with statement-snapshot or readonly-statement-snapshot. Otherwise, false. |
Several statement snapshots can exist on one connection. In the case of nested or interleaved statements running under statement snapshot isolation levels, each one begins a different statement snapshot with its first read or update.
Usually there is only one transaction snapshot per connection (one entry per connection in sa_snapshots with statement_level=0). However, a snapshot associated with a cursor never changes after the cursor's first fetch and a cursor opened WITH HOLD stays open through a commit or rollback. If the cursor has an associated snapshot, then the snapshot also persists. Therefore, it is possible for multiple transaction snapshots to exist for the same connection_num: one for the current transaction snapshot and one or more for old transaction snapshots that persist because of WITH HOLD cursors.
DBA authority required
None
Discuss this page in DocCommentXchange. Send feedback about this page using email. |
Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1 |