The sa_diagnostic_cursor table is owned by the dbo user. Each row describes either an internal or external cursor opened during the logging session.
There are two versions of this table: sa_diagnostic_cursor, and sa_tmp_diagnostic_cursor.
Column name | Column type | Column constraint | Table constraints |
---|---|---|---|
logging_session_id | UNSIGNED INT | NOT NULL |
Primary key. Foreign key references sa_diagnostic_query. |
cursor_id | UNSIGNED BIGINT | NOT NULL |
Primary key. |
query_id | UNSIGNED BIGINT | NOT NULL |
Foreign key references sa_diagnostic_query. |
isolation_level | TINYINT | ||
flags | UNSIGNED INT | ||
forward_fetches | UNSIGNED INT | ||
reverse_fetches | UNSIGNED INT | ||
absolute_fetches | UNSIGNED INT | ||
first_fetch_time_ms | UNSIGNED INT | ||
total_fetch_time_ms | UNSIGNED INT | ||
plan_xml | LONG VARCHAR |
logging_session_id A number uniquely identifying the logging session during which the diagnostic information was gathered.
cursor_id A unique number identifying the cursor.
query_id Identifies the query over which this cursor ranges.
isolation_level Isolation level at which this cursor was opened.
flags Internal use.
forward_fetches Number of forward fetches, including prefetches, done on the cursor.
reverse_fetches Number of reverse fetches, including prefetches, done on the cursor.
absolute_fetches Number of absolute fetches done on the cursor.
first_fetch_time_ms Duration of time spent fetching the first row.
total_fetch_time_ms Duration of time spent fetching. This value does not include application processing time between actual fetches (think time).
plan_xml Detailed plan for cursors that were dumped at the time the cursor was closed. These plans contain detailed statistics where appropriate.