Suppose that you have a procedure with many SQL orders (select, update, insert...).
I am wondering if :
* A single line will be created in V$SQLAREA,
* We could have many lines (related to individual SQL orders in the procedure).
Thanks for the reply.
Every time a statement is executed it is moved into the SQL area and can be seen in the V$SQLAREA table. You can determine which statement a session, say session 10, is currently running by:
where a.address = s.sql_address
and a.hash_value = s.sql_hash_value
and s.sid = 10;
This displays the current statement and as each statement is executed you will see it using this statement. After a statement has been executed it remains in the v$sqlarea table until it is aged out. However, there is no way to associate it with a particular database session.
Hope this helps
Click Here to Expand Forum to Full Width