forked from geekcomputers/Oracle-SQL
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdb_buffer_hr.sql
More file actions
19 lines (16 loc) · 528 Bytes
/
db_buffer_hr.sql
File metadata and controls
19 lines (16 loc) · 528 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
REM Script Name : db_buffer_hr.sql
REM Author : Craig Richards
REM Created :
REM Last Modified :
REM Version : 1.0
REM
REM Modifications :
REM
REM Description : Displays the buffer cache hit ratio
COLUMN BUFFER_POOL_NAME FORMAT A20
SELECT name BUFFER_POOL_NAME, consistent_gets Consistent, db_block_gets Dbblockgets,
physical_reads Physrds,
ROUND(100*(1 - (physical_reads/(consistent_gets + db_block_gets))),2) HitRatio
FROM v$buffer_pool_statistics
WHERE (consistent_gets + db_block_gets) != 0;
REM End of Script