重庆思庄Oracle、、PostgreSQL、Redhat认证学习论坛

标题: mysql 变量之 query_cache_type [打印本页]

作者: jikcheng    时间: 2014-12-24 14:38
标题: mysql 变量之 query_cache_type
query_cache_type 是设置查询时是否从 query_cache 里面取出结果
Option Description
0 or OFF Do not cache results in or retrieve results from the query cache. Note that
this does not deallocate the query cache buffer. To do that, you should set
query_cache_size to 0.
1 or ON Cache all cacheable query results except for those that begin with SELECT
SQL_NO_CACHE.
2 or DEMAND Cache results only for cacheable queries that begin with SELECT SQL_CACHE.

如果设为0 则不从缓存区取出数据。
如果设为1 除了指定 SELECT SQL_NO_CACHE 
如果设为2 指定SELECT SQL_CACHE 才能从缓存去中取出数据。






欢迎光临 重庆思庄Oracle、、PostgreSQL、Redhat认证学习论坛 (http://bbs.cqsztech.com/) Powered by Discuz! X3.2