V$SQL

Information about Sql processes running now.

Columns
   ___________________________
 
   ACTION
   ACTION_HASH
   ADDRESS
   BUFFER_GETS
   CHILD_LATCH
   CHILD_NUMBER
   COMMAND_TYPE
   DISK_READS
   EXECUTIONS
   FETCHES
   FIRST_LOAD_TIME
   HASH_VALUE
   INVALIDATIONS
   KEPT_VERSIONS
   LOADED_VERSIONS
   LOADS
   MODULE
   MODULE_HASH
   OPEN_VERSIONS
   OPTIMIZER_COST
   OPTIMIZER_MODE
   PARSE_CALLS
   PARSING_SCHEMA_ID
   PARSING_USER_ID
   PERSISTENT_MEM
   PLAN_HASH_VALUE
   ROWS_PROCESSED
   RUNTIME_MEM
   SERIALIZABLE_ABORTS
   SHARABLE_MEM
   SORTS
   SQL_TEXT
   SQLTYPE
   TYPE_CHK_HEAP
   USERS_EXECUTING
   USERS_OPENING

Examples

SQL > Select substr(sql_text,0,80),
decode(command_type,2,'INSERT'),
executions
From V$SQL
Where command_type = 2
Order By executions;

SQL > Select substr(sql_text,0,80),
decode(command_type,3,'SELECT'),
executions
From V$SQL
Where command_type = 3
Order By executions;

List of command_type values with meaning:

Insert 2
Select 3
Update 6
Delete 7
Lock Table 26
Alter Database 35
Alter Session 42
Commit 44
Rollback 45
Savepoint 46
Begin/Declare 47

Related:

V$OPEN_CURSOR 
V$SQLAREA 
V$SQLTEXT 
V$SQLTEXT_WITH_NEWLINES 
V$SQL_BIND_DATA 
V$SQL_BIND_METADATA 
V$SQL_CURSOR 
V$SQL_SHARED_MEMORY


© Copyright SS64.com 1999-2014
Some rights reserved