How to preload tables into INNODB buffer pool with MySQL?

前端 未结 2 683
野的像风
野的像风 2020-12-12 23:20

I have an e-commerce application that uses MySQL, and I\'d like it to be faster. When a part # is accessed on the website that has been accessed before, the part loads quick

2条回答
  •  孤城傲影
    2020-12-12 23:44

    This query will return table names in your database, so you don't have to input them manually:

    SELECT TABLE_NAME FROM information_schema.TABLES WHERE TABLE_SCHEMA = 'database name'
    

    Then for each table name force table scan.

提交回复
热议问题