SQL statement cache information in onstat -g ssc output
The onstat -g ssc command displays summary information for the SQL statement cache.
The onstat -g ssc command displays the following information for the SQL statement cache.
Column | Description |
---|---|
#lrus | The number of LRU queues. Multiple LRU queues facilitate concurrent lookup and insertion of cache entries. |
currsize | The number of bytes currently allocated to entries in the SQL statement cache |
maxsize | The number of bytes specified in the STMT_CACHE_SIZE configuration parameter |
poolsize | The cumulative number of bytes for all pools in the SQL statement cache. Use the onstat -g ssc pool option to monitor individual pool usage. |
#hits | Setting of the STMT_CACHE_HITS configuration parameter, which specifies the number of times that a query is executed before it is inserted into the cache |
nolimit | Setting of STMT_CACHE_NOLIMIT configuration parameter |
The onstat -g ssc command lists the following information for each fully cached entry in the cache. The onstat -g ssc all option lists the following information for both the fully cached entries and key-only entries.
Column | Description |
---|---|
lru | The LRU identifier |
hash | The hash-bucket identifier |
ref_cnt | The number of sessions currently using this statement |
hits | The number of times that users read the query from the cache, excluding the first time the statement entered the cache |
flags | Shows flag codes. The flag codes for position 1 are:
The flag codes for position 2 are:
|
heap_ptr | Pointer to the associated heap for the statement |
database | Database against which the SQL statement is executed |
user | User executing the SQL statement |
statement | Statement text as it would be used to test for a match |