v$sqltext vs v$sqlarea
I'm trying to understand what the critical difference between these 2 views (other than the obvious, which is v$sqlarea has a lot of statistical information).
Let me rephrase...
Why would I want to query v$sqltext, and not just query v$sqlarea?
v$sqltext really only has the hash_value and the sqltext - with the sql_text broken into various lines and pieced together by the pieces column.
v$sqlarea has both hash_value, sql_text, and a bunch of statistical information, PLUS!! the sql_text contains the sql statement as a whole (not broken up like v$sqltext).
In term of the hash_value and sqltext, is the data in these 2 views different in any sense (other than obviously that v$sqlarea has statistics)?
If not, It seems useless having v$sqlarea already... do you agree?
Thanks for that link. So it seems that v$sqlarea will "cutoff" the actual sql statement if it exceeds 1000 bytes. For my practical use, this would be a significant difference. I guess I would still need to rely on v$sqltext to get the entire sql stmt and use v$sqlarea for stats.
Click Here to Expand Forum to Full Width