General error: 1651 Query cache is disabled; restart the server with query_cache_type=1 to enable it

后端 未结 1 1319
爱一瞬间的悲伤
爱一瞬间的悲伤 2021-01-29 14:07

I am getting this error when I\'m trying to connect using PDO.

General error: 1651 Query cache is disabled; restart the server with query_cache_type=1 to enable          


        
相关标签:
1条回答
  • 2021-01-29 14:27

    This is a strange behavior of query_cache_type such that cannot be enabled if it wasn't enabled when the mysqld process started. But if it was enabled at startup, you can set query_cache_type "off" and then back on again if you need to.

    That said, I would strongly encourage you to reconsider using the query cache at all. MySQL 8.0 has retired support for the query cache and removed it from the product. It's still a feature in MySQL 5.7, but it's deprecated as of 5.7.20.

    0 讨论(0)
提交回复
热议问题