当前位置:数据库 > Oracle >>

oracle的结果集缓存

oracle的结果集缓存
 
oracle 调整结果集缓存,只有3个参数。
 
RESULT_CACHE_MAX_SIZE=500M /* Megabytes 
RESULT_CACHE_MAX_RESULT=20 /* Percentage 
RESULT_CACHE_REMOTE_EXPIRATION=3600 /* Minutes 
 
但是在 result_cache_mode 为force 的时候才会去保存所有的查询,在manual 的时候需要+HINT 来enable .
 
alter session set result_cache_mode=force;
 
show parameter result_cache
 
NAME                 TYPE     VALUE
------------------------------------ ----------- ------------------------------
client_result_cache_lag      big integer 3000
client_result_cache_size     big integer 0
result_cache_max_result      integer     5
result_cache_max_size         big integer 5984K
result_cache_mode         string     MANUAL
result_cache_remote_expiration     integer     0
查询下内存分配情况
 
 
SQL> SET SERVEROUTPUT ON
SQL> execute dbms_result_cache.memory_report
R e s u l t C a c h e M e m o r y    R e p o r t
[Parameters]
Block Size     = 1K bytes
Maximum Cache Size = 5984K bytes (5984 blocks)
Maximum Result Size = 299K bytes (299 blocks)
[Memory]
Total Memory = 174752 bytes [0.027% of the Shared Pool]
... Fixed Memory = 10696 bytes [0.002% of the Shared Pool]
... Dynamic Memory = 164056 bytes [0.026% of the Shared Pool]
....... Overhead = 131288 bytes
....... Cache Memory = 32K bytes (32 blocks)
........... Unused Memory = 30 blocks
........... Used Memory = 2 blocks
............... Dependencies = 1 blocks (1 count)
............... Results = 1 blocks
................... SQL = 1 blocks (1 count)
 
PL/SQL procedure successfully completed.
好像只有oracle 有这个东西,DB2 和mysql 都没有。
 
Oracle
MySQL
Access
SQLServer
DB2
Excel
SQLite
SYBASE
Postgres
如果你遇到数据库难题:
请访问www.zzzyk.com 试试
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,