SQL ScriptFree Memory in SGA |
This script list the total memory in the shared_pool and the amount of free memory. (Remember: too much free memory in the shared_pool is wasteful and may be better used elsewhere !)
None
col value form 999,999,999,999 heading "Shared Pool Size" col bytes form 999,999,999,999 heading "Free Bytes" col percentfree form 999 heading "Percent Free" spool freesga.lst select pool , to_number(v$parameter.value) value, v$sgastat.bytes, (v$sgastat.bytes/v$parameter.value)*100 percentfree from v$sgastat, v$parameter where v$sgastat.name = 'free memory' and pool='shared pool' and v$parameter.name = 'shared_pool_size'; spool off
Return to Index of SQL Scripts
Home
|
Company Profile
|
Services
|
Contact Us
|
SQL scripts and tips
|
Quiz
|