`

mysql 清理碎片

阅读更多
显示你数据库中存在碎片的全部列表:
  select table_schema, table_name, data_free, engine
   from information_schema.tables
    where table_schema not in ('information_schema', 'mysql') and data_free > 0;

如果你发现一些列表中包含了大量的数据留空现象,那么对其进行优化是绝对值得的,因为这一过程会大大提升列表的读取性能及应用表现。
  optimize table tableName;
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics